e-mission / e-mission-docs

Repository for docs and issues. If you need help, please file an issue here. Public conversations are better for open source projects than private email.
https://e-mission.readthedocs.io/en/latest
BSD 3-Clause "New" or "Revised" License
15 stars 34 forks source link

Dashboard changes fit-and-finish feedback #696

Closed shankari closed 2 years ago

shankari commented 2 years ago

Feedback on dashboard changes fit-and-finish

shankari commented 2 years ago

Another potential addition: Add calculation details to FAQ

shankari commented 2 years ago

Another potential addition: Add "air" mode to have the best estimate of carbon footprint

shankari commented 2 years ago

wrt the "air" mode addition, we should also go through and fix the existing labels to say "air" so that the footprint calculations work. This is by necessity manual since a human needs to go through and find the mappings. Also, we need to change not only the user mappings, but also any inferred values that use the user mappings.

So this change happened in multiple steps.

Step 1: Print out the existing labels

Printing out the user inputs is fairly straightforward because we can directly use a projection. However, the inferred labels are harder because they are stored as lists we need to iterate over. So I ended up writing the attached script.

Step 2: Determine the labels to be mapped

The result of the mapping on staging is as below. This makes the mapping a little tricky - how do we deal with car-fly or fly-drive-bike-drive-fly? We don't want to override the user input and to lose the information that is captured in those labels.

So the current decision is to only map the uncomplicated labels. Users can change the more complicated labels later if they wish, but we will not modify them. Otherwise, the complicated labels will continue generate a range. This is consistent with what would have happened if we did have an air mode.

Connecting to database URL stage-db
---------- inputs ----------
__________ manual/mode_confirm __________
['airplane', 'bike', 'bikeshare', 'bus', 'car-fly', 'dog_walk', 'drove_alone', 'electric_car', 'flight', 'fly-drive-bike-drive-fly', 'free_shuttle', 'gondola', 'houseboat', 'kayak', 'motorboat', 'multi-modal', 'multi-modal_car- regular bike- car', 'multi-modal_drive to bike to drive', 'multi_modal', 'not_a_trip', 'pilot_ebike', 'plane', 'pontoon_boat', 'run', 'sailboat', 'scooter_(non-motorized, non-share)', 'scootershare', 'shared_ride', 'sharedride_and walk', 'sharedrideandwalk', 'ski', 'subway', 'taxi', 'train', 'tramway', 'walk', 'walk_+ drove alone']
__________ analysis/confirmed_trip __________
['airplane', 'bike', 'bikeshare', 'bus', 'car-fly', 'drove_alone', 'electric_car', 'fly-drive-bike-drive-fly', 'free_shuttle', 'gondola', 'houseboat', 'kayak', 'motorboat', 'multi-modal', 'multi-modal_car- regular bike- car', 'multi-modal_drive to bike to drive', 'multi_modal', 'not_a_trip', 'pilot_ebike', 'plane', 'pontoon_boat', 'run', 'sailboat',
'scooter_(non-motorized, non-share)', 'scootershare', 'shared_ride', 'sharedride_and walk', 'sharedrideandwalk', 'ski', 'subway', 'taxi', 'train', 'tramway', 'walk', 'walk_+ drove alone']
---------- inferred_labels ----------
__________ label predictions __________
['electric_car', 'multi-modal', 'pilot_ebike', 'sharedride_and walk', 'run', 'walk_+ drove alone', 'multi-modal_car- regular bike- car', 'pontoon_boat', 'motorboat', 'not_a_trip', 'tramway', 'houseboat', 'shared_ride', 'gondola', 'bike', 'multi-modal_drive to bike to drive', 'taxi', 'plane', 'free_shuttle', 'train', 'sharedrideandwalk', 'scootershare', 'drove_alone', 'scooter_(non-motorized, non-share)', 'bikeshare', 'bus', 'kayak', 'multi_modal', 'walk']
__________ inferred trips __________
['electric_car', 'multi-modal', 'pilot_ebike', 'sharedride_and walk', 'run', 'walk_+ drove alone', 'multi-modal_car- regular bike- car', 'pontoon_boat', 'motorboat', 'not_a_trip', 'tramway', 'houseboat', 'shared_ride', 'gondola', 'bike', 'multi-modal_drive to bike to drive', 'taxi', 'plane', 'free_shuttle', 'train', 'sharedrideandwalk', 'scootershare', 'drove_alone', 'scooter_(non-motorized, non-share)', 'bikeshare', 'bus', 'kayak', 'multi_modal', 'walk']
__________ expected trips __________
['electric_car', 'multi-modal', 'pilot_ebike', 'sharedride_and walk', 'run', 'walk_+ drove alone', 'multi-modal_car- regular bike- car', 'pontoon_boat', 'motorboat', 'not_a_trip', 'tramway', 'houseboat', 'shared_ride', 'gondola', 'bike', 'multi-modal_drive to bike to drive', 'taxi', 'plane', 'free_shuttle', 'train', 'sharedrideandwalk', 'scootershare', 'drove_alone', 'scooter_(non-motorized, non-share)', 'bikeshare', 'bus', 'kayak', 'multi_modal', 'walk']
__________ confirmed trips __________
['electric_car', 'multi-modal', 'pilot_ebike', 'sharedride_and walk', 'run', 'walk_+ drove alone', 'multi-modal_car- regular bike- car', 'pontoon_boat', 'motorboat', 'not_a_trip', 'tramway', 'houseboat', 'shared_ride', 'gondola', 'bike', 'multi-modal_drive to bike to drive', 'taxi', 'plane', 'free_shuttle', 'train', 'sharedrideandwalk', 'scootershare', 'drove_alone', 'scooter_(non-motorized, non-share)', 'bikeshare', 'bus', 'kayak', 'multi_modal', 'walk']

Note also that the air trips are so rare that they don't make it to the model or to the inferred labels. Let's see if that is true for other programs as well.

fc labels ``` Connecting to database URL fc-db ---------- inputs ---------- __________ manual/mode_confirm __________ ['airplane_/ flight', 'airport_shuttle', 'bike', 'bikeshare', 'bus', 'cart', 'dropped_my truck at the repair shop and biked to work.', 'drove_alone', 'jog', 'not_a_trip', 'pilot_ebike', 'plane', 'running', 'scootershare', 'shared_ride', 'taxi', 'time_at work', 'tow_truck', 'train', 'walk', 'work'] __________ analysis/confirmed_trip __________ ['airplane_/ flight', 'airport_shuttle', 'bike', 'bus', 'cart', 'dropped_my truck at the repair shop and biked to work.', 'drove_alone', 'jog', 'not_a_trip', 'pilot_ebike', 'plane', 'running', 'shared_ride', 'taxi', 'time_at work', 'tow_truck', 'train', 'walk', 'work'] ---------- inferred_labels ---------- __________ label predictions __________ ['shared_ride', 'bus', 'taxi', 'pilot_ebike', 'work', 'bike', 'time_at work', 'jog', 'drove_alone', 'cart', 'dropped_my truck at the repair shop and biked to work.', 'running', 'walk', 'not_a_trip'] __________ inferred trips __________ ['shared_ride', 'bus', 'taxi', 'pilot_ebike', 'work', 'bike', 'time_at work', 'jog', 'drove_alone', 'cart', 'dropped_my truck at the repair shop and biked to work.', 'running', 'walk', 'not_a_trip'] __________ expected trips __________ ['shared_ride', 'bus', 'taxi', 'pilot_ebike', 'work', 'bike', 'time_at work', 'jog', 'drove_alone', 'cart', 'dropped_my truck at the repair shop and biked to work.', 'running', 'walk', 'not_a_trip'] __________ confirmed trips __________ ['shared_ride', 'bus', 'taxi', 'pilot_ebike', 'work', 'bike', 'time_at work', 'jog', 'drove_alone', 'cart', 'dropped_my truck at the repair shop and biked to work.', 'running', 'walk', 'not_a_trip'] ```
sc labels ``` Connecting to database URL sc-db ---------- inputs ---------- __________ manual/mode_confirm __________ ['airplane', 'bike', 'bikeshare', 'bus', 'drove_alone', 'free_shuttle', 'hike', 'needed_to check car battery', 'not_a_trip', 'pilot_ebike', 'ride', 'scootershare', 'shared_ride', 'taxi', 'train', 'walk'] __________ analysis/confirmed_trip __________ ['airplane', 'bike', 'bikeshare', 'bus', 'drove_alone', 'free_shuttle', 'not_a_trip', 'pilot_ebike', 'ride', 'scootershare', 'shared_ride', 'taxi', 'train', 'walk'] ---------- inferred_labels ---------- __________ label predictions __________ ['drove_alone', 'bikeshare', 'bike', 'pilot_ebike', 'bus', 'shared_ride', 'taxi', 'walk', 'not_a_trip', 'train'] __________ inferred trips __________ ['drove_alone', 'bikeshare', 'bike', 'pilot_ebike', 'bus', 'shared_ride', 'taxi', 'walk', 'not_a_trip', 'train'] __________ expected trips __________ ['drove_alone', 'bikeshare', 'bike', 'pilot_ebike', 'bus', 'shared_ride', 'taxi', 'walk', 'not_a_trip', 'train'] __________ confirmed trips __________ ['drove_alone', 'bikeshare', 'bike', 'pilot_ebike', 'bus', 'shared_ride', 'taxi', 'walk', 'not_a_trip', 'train'] ```
4c labels ``` Connecting to database URL 4c-db ---------- inputs ---------- __________ manual/mode_confirm __________ ['airplane', 'bike', 'bikeshare', 'boat', 'boats', 'bus', 'canoe', 'drove_alone', 'ferry', 'free_shuttle', 'not_a_trip', 'paddleboard', 'pilot_ebike', 'plane', 'scootershare', 'shared_ride', 'skateboard', 'taxi', 'train', 'walk'] __________ analysis/confirmed_trip __________ ['airplane', 'bike', 'bikeshare', 'boat', 'boats', 'bus', 'canoe', 'drove_alone', 'ferry', 'free_shuttle', 'not_a_trip', 'paddleboard', 'pilot_ebike', 'plane', 'shared_ride', 'skateboard', 'taxi', 'walk'] ---------- inferred_labels ---------- __________ label predictions __________ ['shared_ride', 'drove_alone', 'walk', 'not_a_trip', 'taxi', 'bike', 'skateboard', 'airplane', 'bikeshare', 'pilot_ebike', 'bus', 'paddleboard'] __________ inferred trips __________ ['shared_ride', 'drove_alone', 'walk', 'not_a_trip', 'taxi', 'bike', 'skateboard', 'airplane', 'bikeshare', 'pilot_ebike', 'bus', 'paddleboard'] __________ expected trips __________ ['shared_ride', 'drove_alone', 'walk', 'not_a_trip', 'taxi', 'bike', 'skateboard', 'airplane', 'bikeshare', 'pilot_ebike', 'bus', 'paddleboard'] __________ confirmed trips __________ ['shared_ride', 'drove_alone', 'walk', 'not_a_trip', 'taxi', 'bike', 'skateboard', 'airplane', 'bikeshare', 'pilot_ebike', 'bus', 'paddleboard'] ```
cc labels ``` Connecting to database URL cc-db ---------- inputs ---------- __________ manual/mode_confirm __________ ['7k_run and then brunch', 'aircraft', 'airplane', 'bike', 'bike_to bus', 'bike_to bus, then bus, then bike to work', 'bikeshare', 'boat', 'bus', 'bus_to bike', 'car', 'drive_then walk then bus', 'drove_alone', 'e-bike_to bus', 'electric_golf cart', 'electric_vehicle, with others', 'emergency_vehicle', 'fire_dept', 'flight', 'free_shuttle', 'golf_cart', 'horse_back ride', "i_don't know", 'jog', 'jogging', 'not_a_trip', 'pilot_e-bike to bus', 'pilot_e-bike, transfer to bus', 'pilot_ebike', 'plane', 'run', 'scootershare', 'shared_ride', 'ski', 'skiing', 'taxi', 'train', 'train_to airplane', 'walk'] __________ analysis/confirmed_trip __________ ['7k_run and then brunch', 'aircraft', 'airplane', 'bike', 'bike_to bus', 'bike_to bus, then bus, then bike to work', 'bikeshare', 'boat', 'bus', 'bus_to bike', 'car', 'drive_then walk then bus', 'drove_alone', 'e-bike_to bus', 'electric_golf cart', 'electric_vehicle, with others', 'emergency_vehicle', 'fire_dept', 'flight', 'free_shuttle', 'golf_cart', 'horse_back ride', "i_don't know", 'jog', 'jogging', 'not_a_trip', 'pilot_e-bike to bus', 'pilot_e-bike, transfer to bus', 'pilot_ebike', 'plane', 'run', 'scootershare', 'shared_ride', 'ski', 'skiing', 'taxi', 'train', 'train_to airplane', 'walk'] ---------- inferred_labels ---------- __________ label predictions __________ ['boat', 'pilot_ebike', 'bike_to bus, then bus, then bike to work', 'pilot_e-bike, transfer to bus', 'taxi', 'jogging', 'bike', 'walk', 'emergency_vehicle', 'golf_cart', 'free_shuttle', 'bike_to bus', 'bus', 'drove_alone', 'drive_then walk then bus', 'bus_to bike', 'not_a_trip', 'car', 'electric_vehicle, with others', 'e-bike_to bus', 'pilot_e-bike to bus', "i_don't know", 'run', 'shared_ride', 'train', 'jog', 'ski', 'electric_golf cart', 'bikeshare'] __________ inferred trips __________ ['boat', 'pilot_ebike', 'bike_to bus, then bus, then bike to work', 'pilot_e-bike, transfer to bus', 'taxi', 'jogging', 'bike', 'walk', 'emergency_vehicle', 'golf_cart', 'free_shuttle', 'bike_to bus', 'bus', 'drove_alone', 'drive_then walk then bus', 'bus_to bike', 'not_a_trip', 'car', 'electric_vehicle, with others', 'e-bike_to bus', 'pilot_e-bike to bus', "i_don't know", 'run', 'shared_ride', 'train', 'jog', 'ski', 'electric_golf cart', 'bikeshare'] __________ expected trips __________ ['boat', 'pilot_ebike', 'bike_to bus, then bus, then bike to work', 'pilot_e-bike, transfer to bus', 'taxi', 'jogging', 'bike', 'walk', 'emergency_vehicle', 'golf_cart', 'free_shuttle', 'bike_to bus', 'bus', 'drove_alone', 'drive_then walk then bus', 'bus_to bike', 'not_a_trip', 'car', 'electric_vehicle, with others', 'e-bike_to bus', 'pilot_e-bike to bus', "i_don't know", 'run', 'shared_ride', 'train', 'jog', 'ski', 'electric_golf cart', 'bikeshare'] __________ confirmed trips __________ ['boat', 'pilot_ebike', 'bike_to bus, then bus, then bike to work', 'pilot_e-bike, transfer to bus', 'taxi', 'jogging', 'bike', 'walk', 'emergency_vehicle', 'golf_cart', 'free_shuttle', 'bike_to bus', 'bus', 'drove_alone', 'drive_then walk then bus', 'bus_to bike', 'not_a_trip', 'car', 'electric_vehicle, with others', 'e-bike_to bus', 'pilot_e-bike to bus', "i_don't know", 'run', 'shared_ride', 'train', 'jog', 'ski', 'electric_golf cart', 'bikeshare'] ```
pc labels ``` Connecting to database URL pc-db ---------- inputs ---------- __________ manual/mode_confirm __________ ['bike', 'bikeshare', 'bus', 'car/walk', 'car_with others/walk', 'combined_at work and drive home', 'combined_car alone and car with others', 'combined_car alone with car with others', 'combined_car with others and alone', 'combined_car with others and car alone', 'combined_drove in car alone and with others', 'deliveries_at work', 'drove_alone', 'free_shuttle', 'not_a_trip', 'pick_up bike', 'pilot_ebike', 'plane', 'scootershare', 'shared_ride', 'taxi', 'train', 'walk', 'walk/drive', 'work'] __________ analysis/confirmed_trip __________ ['bike', 'bikeshare', 'bus', 'car/walk', 'car_with others/walk', 'combined_at work and drive home', 'combined_car alone and car with others', 'combined_car alone with car with others', 'combined_car with others and alone', 'combined_car with others and car alone', 'combined_drove in car alone and with others', 'deliveries_at work', 'drove_alone', 'not_a_trip', 'pick_up bike', 'pilot_ebike', 'plane', 'shared_ride', 'taxi', 'walk', 'walk/drive', 'work'] ---------- inferred_labels ---------- __________ label predictions __________ ['pilot_ebike', 'drove_alone', 'combined_drove in car alone and with others', 'deliveries_at work', 'walk', 'bus', 'shared_ride', 'bikeshare', 'combined_car alone with car with others', 'combined_car alone and car with others', 'combined_car with others and car alone', 'bike', 'work', 'combined_car with others and alone', 'car_with others/walk', 'not_a_trip'] __________ inferred trips __________ ['pilot_ebike', 'drove_alone', 'combined_drove in car alone and with others', 'deliveries_at work', 'walk', 'bus', 'shared_ride', 'bikeshare', 'combined_car alone with car with others', 'combined_car alone and car with others', 'combined_car with others and car alone', 'bike', 'work', 'combined_car with others and alone', 'car_with others/walk', 'not_a_trip'] __________ expected trips __________ ['pilot_ebike', 'drove_alone', 'combined_drove in car alone and with others', 'deliveries_at work', 'walk', 'bus', 'shared_ride', 'bikeshare', 'combined_car alone with car with others', 'combined_car alone and car with others', 'combined_car with others and car alone', 'bike', 'work', 'combined_car with others and alone', 'car_with others/walk', 'not_a_trip'] __________ confirmed trips __________ ['pilot_ebike', 'drove_alone', 'combined_drove in car alone and with others', 'deliveries_at work', 'walk', 'bus', 'shared_ride', 'bikeshare', 'combined_car alone with car with others', 'combined_car alone and car with others', 'combined_car with others and car alone', 'bike', 'work', 'combined_car with others and alone', 'car_with others/walk', 'not_a_trip'] ```
vail labels ``` ---------- inputs ---------- __________ manual/mode_confirm __________ ['bike', 'bikeshare', 'bus', 'car', 'combination_football game, dinner, drove friend home', 'drove_alone', 'electric_vehicle', 'free_shuttle', 'not_a_trip', 'pilot_ebike', 'plane', 'scootershare', 'shared_ride', 'skiing', 'subway', 'taxi', 'train', 'walk'] __________ analysis/confirmed_trip __________ ['bike', 'bus', 'car', 'combination_football game, dinner, drove friend home', 'drove_alone', 'electric_vehicle', 'free_shuttle', 'not_a_trip', 'pilot_ebike', 'plane', 'shared_ride', 'skiing', 'subway', 'taxi', 'train', 'walk'] ---------- inferred_labels ---------- __________ label predictions __________ ['bus', 'walk', 'shared_ride', 'car', 'free_shuttle', 'electric_vehicle', 'drove_alone', 'pilot_ebike', 'not_a_trip'] __________ inferred trips __________ ['bus', 'walk', 'shared_ride', 'car', 'free_shuttle', 'electric_vehicle', 'drove_alone', 'pilot_ebike', 'not_a_trip'] __________ expected trips __________ ['bus', 'walk', 'shared_ride', 'car', 'free_shuttle', 'electric_vehicle', 'drove_alone', 'pilot_ebike', 'not_a_trip'] __________ confirmed trips __________ ['bus', 'walk', 'shared_ride', 'car', 'free_shuttle', 'electric_vehicle', 'drove_alone', 'pilot_ebike', 'not_a_trip'] ```

Alas, no. The staging inferred labels include plane and the 4c inferred labels include airplane

shankari commented 2 years ago

Fortunately, each of the inferred labels is fairly unique and has only one entry.

Stage

Connecting to database URL stage-db
__________ label predictions __________
[{'labels': {'mode_confirm': 'plane', 'purpose_confirm': 'travel', 'replaced_mode': 'plane'}, 'p': 0.8}]
[{'labels': {'mode_confirm': 'plane', 'purpose_confirm': 'travel', 'replaced_mode': 'plane'}, 'p': 0.8}]
[ObjectId('611fde31688f92fbb6e6bf33'), ObjectId('611fde32688f92fbb6e6bfc3')]
[ObjectId('611fde31688f92fbb6e6bf33'), ObjectId('611fde32688f92fbb6e6bfc3')]

4c

__________ label predictions __________
[{'labels': {'mode_confirm': 'airplane', 'purpose_confirm': 'entertainment', 'replaced_mode': 'no_travel'}, 'p': 0.8}]
[{'labels': {'mode_confirm': 'airplane', 'purpose_confirm': 'entertainment', 'replaced_mode': 'no_travel'}, 'p': 0.8}]
[{'labels': {'mode_confirm': 'airplane', 'purpose_confirm': 'home'}, 'p': 0.8}]
[ObjectId('61208a2fb8ec5759a7bfd2c5'), ObjectId('61208a2fb8ec5759a7bfd2cb'), ObjectId('61208a30b8ec5759a7bfd32b')]
[ObjectId('61208a2fb8ec5759a7bfd2c5'), ObjectId('61208a2fb8ec5759a7bfd2cb'), ObjectId('61208a30b8ec5759a7bfd32b')]
shankari commented 2 years ago

Created a script and fixed both the user inputs and the inferred labels

Connecting to database URL stage-db
---------- inputs ----------
__________ manual/mode_confirm __________
<pymongo.results.UpdateResult object at 0x7fe29c85eaa0>
__________ analysis/confirmed_trip __________
<pymongo.results.UpdateResult object at 0x7fe29c869690>
---------- inferred_labels ----------
__________ label predictions __________
Fixing projection {'_id': ObjectId('611fde31688f92fbb6e6bf33'), 'data': {'prediction': [{'labels': {'mode_confirm': 'plane', 'purpose_confirm': 'travel', 'replaced_mode': 'plane'}, 'p': 0.8}]}}
Update response <pymongo.results.UpdateResult object at 0x7fe28fb89e10>
Fixed projection {'_id': ObjectId('611fde31688f92fbb6e6bf33'), 'data': {'prediction': [{'labels': {'mode_confirm': 'air', 'purpose_confirm': 'travel', 'replaced_mode': 'plane'}, 'p': 0.8}]}}
Fixing projection {'_id': ObjectId('611fde32688f92fbb6e6bfc3'), 'data': {'prediction': [{'labels': {'mode_confirm': 'plane', 'purpose_confirm': 'travel', 'replaced_mode': 'plane'}, 'p': 0.8}]}}
Update response <pymongo.results.UpdateResult object at 0x7fe296f68280>
Fixed projection {'_id': ObjectId('611fde32688f92fbb6e6bfc3'), 'data': {'prediction': [{'labels': {'mode_confirm': 'air', 'purpose_confirm': 'travel', 'replaced_mode': 'plane'}, 'p': 0.8}]}}
None

and we now only have air

Connecting to database URL stage-db
---------- inputs ----------
__________ manual/mode_confirm __________
['air', 'bike', 'bikeshare', 'bus', 'car-fly', 'dog_walk', 'drove_alone', 'electric_car', 'fly-drive-bike-drive-fly', 'free_shuttle', 'gondola', 'houseboat', 'kayak', 'motorboat', 'multi-modal', 'multi-modal_car- regular bike- car', 'multi-modal_drive to bike to drive', 'multi_modal', 'not_a_trip', 'pilot_ebike', 'pontoon_boat', 'run', 'sailboat', 'scooter_(non-motorized, non-share)', 'scootershare', 'shared_ride', 'sharedride_and walk', 'sharedrideandwalk', 'ski', 'subway', 'taxi', 'train', 'tramway', 'walk', 'walk_+ drove alone']
__________ analysis/confirmed_trip __________
['air', 'bike', 'bikeshare', 'bus', 'car-fly', 'drove_alone', 'electric_car', 'fly-drive-bike-drive-fly', 'free_shuttle', 'gondola', 'houseboat', 'kayak', 'motorboat', 'multi-modal', 'multi-modal_car- regular bike- car', 'multi-modal_drive to bike to drive', 'multi_modal', 'not_a_trip', 'pilot_ebike', 'pontoon_boat', 'run', 'sailboat', 'scooter_(non-motorized, non-share)', 'scootershare', 'shared_ride', 'sharedride_and walk', 'sharedrideandwalk', 'ski', 'subway', 'taxi', 'train', 'tramway', 'walk', 'walk_+ drove alone']
---------- inferred_labels ----------
__________ label predictions __________
['train', 'multi-modal', 'sharedrideandwalk', 'sharedride_and walk', 'pontoon_boat', 'free_shuttle', 'scooter_(non-motorized, non-share)', 'multi-modal_drive to bike to drive', 'gondola', 'run', 'kayak', 'taxi', 'multi_modal', 'houseboat', 'walk_+ drove alone', 'not_a_trip', 'multi-modal_car- regular bike- car', 'tramway', 'motorboat', 'pilot_ebike', 'shared_ride', 'bike', 'scootershare', 'drove_alone', 'bus', 'bikeshare', 'electric_car', 'air', 'walk']
__________ inferred trips __________
['train', 'multi-modal', 'sharedrideandwalk', 'sharedride_and walk', 'pontoon_boat', 'free_shuttle', 'scooter_(non-motorized, non-share)', 'multi-modal_drive to bike to drive', 'gondola', 'run', 'kayak', 'taxi', 'multi_modal', 'houseboat', 'walk_+ drove alone', 'not_a_trip', 'multi-modal_car- regular bike- car', 'tramway', 'motorboat', 'pilot_ebike', 'shared_ride', 'bike', 'scootershare', 'drove_alone', 'bus', 'bikeshare', 'electric_car', 'air', 'walk']
__________ expected trips __________
['train', 'multi-modal', 'sharedrideandwalk', 'sharedride_and walk', 'pontoon_boat', 'free_shuttle', 'scooter_(non-motorized, non-share)', 'multi-modal_drive to bike to drive', 'gondola', 'run', 'kayak', 'taxi', 'multi_modal', 'houseboat', 'walk_+ drove alone', 'not_a_trip', 'multi-modal_car- regular bike- car', 'tramway', 'motorboat', 'pilot_ebike', 'shared_ride', 'bike', 'scootershare', 'drove_alone', 'bus', 'bikeshare', 'electric_car', 'air', 'walk']
__________ confirmed trips __________
['train', 'multi-modal', 'sharedrideandwalk', 'sharedride_and walk', 'pontoon_boat', 'free_shuttle', 'scooter_(non-motorized, non-share)', 'multi-modal_drive to bike to drive', 'gondola', 'run', 'kayak', 'taxi', 'multi_modal', 'houseboat', 'walk_+ drove alone', 'not_a_trip', 'multi-modal_car- regular bike- car', 'tramway', 'motorboat', 'pilot_ebike', 'shared_ride', 'bike', 'scootershare', 'drove_alone', 'bus', 'bikeshare', 'electric_car', 'air', 'walk']
shankari commented 2 years ago

Related scripts:

change_labels_script.tar.gz

a tmp/modify_unique_user_inputs.py
a tmp/print_air_inferred_labels.py
a tmp/print_unique_labels.py

Running them on the server was:

PROGRAM=$1
sudo docker cp /tmp/print_unique_labels.py $PROGRAM-stack_$PROGRAM-analysis-server_1:/tmp
sudo docker exec -it $PROGRAM-stack_$PROGRAM-analysis-server_1 /bin/bash -c 'cd e-mission-server && \
        source setup/activate.sh && \
        echo "Running at "`date` && \
        cat conf/storage/db.conf && \
        ./e-mission-py.bash /tmp/print_unique_labels.py'

Related logs: update_air_mode_results.log.gz post_modification_check.log.gz

shankari commented 2 years ago

For smartphone calculations, the EPA says: 8.22 x 10^-6 metric tons CO2/smartphone charged https://www.epa.gov/energy/greenhouse-gases-equivalencies-calculator-calculations-and-references

1 metric ton = 1000 kg So this is 8.22 x 10^-3 kg CO2/smartphone charged So x kg CO2 = x / 8.22 x 10^-3 smartphone charges