conference_footprint

compute the CO2 footprint of an academic conference
git clone https://a3nm.net/git/conference_footprint/
Log | Files | Refs

commands.sh (1336B)


      1 #!/bin/bash
      2 
      3 # Here are the raw shell commands that were used to process the data
      4 # Note that the registation file is not versioned here because it contains
      5 # personal information
      6 
      7 # raw_data.csv generated from framaforms export by keeping only relevant rows
      8 # and removing headers
      9 # and manually removing one participant with conflicting information
     10 cat highlights_and_jewels_of_automata_theory_2024_raw_data.csv | awk -F '\t' '$7 != "Online"' > highlights_and_jewels_of_automata_theory_2024_onsite.csv
     11 cat highlights_and_jewels_of_automata_theory_2024_onsite.csv | awk -F '\t' '($9 != "Local Participant")'
     12 > highlights_and_jewels_of_automata_theory_2024_onsite_nonlocal.csv
     13 
     14 # highlights_and_jewels_of_automata_theory_2024_onsite_nonlocal_manualclean.csv
     15 # was then manually edited following the README
     16 
     17 (cut -f 13 highlights_and_jewels_of_automata_theory_2024_onsite_nonlocal_manualclean.csv ; cut -f 10 highlights_and_jewels_of_automata_theory_2024_onsite_nonlocal_manualclean.csv) | sort  | uniq > locations.txt
     18 ./geocode.py < locations.txt > locations_with_latlon.txt
     19 ./generate_trips.py 44.84044 -0.5805 0.2
     20 ./co2.py < trips_anonymized.csv
     21 # creates footprints.txt
     22 
     23 # 50 is twice the number of local participants
     24 cat <(yes 0 | head -50) <(cat footprints.txt | sort -n | awk '{s+= $0; print s}') > footprints_withlocal_cumul.txt