Skip to content

Transport updates - #53

Open
nreinicke wants to merge 9 commits into
dsgrid:mainfrom
nreinicke:ndr/transport-updates
Open

Transport updates#53
nreinicke wants to merge 9 commits into
dsgrid:mainfrom
nreinicke:ndr/transport-updates

Conversation

@nreinicke

@nreinicke nreinicke commented Dec 11, 2025

Copy link
Copy Markdown

Updates to include a new transportation load dataset as well as a transportation vehicle stock dataset. I felt a little awkward adding the vehicle stock as an "enduse" and so I would be curious to hear if there is a better way to include that metric into the project.

All of the data and missing association files are stashed on kestrel at the location: /projects/evix/evbps/grid-team-deliverables/ief/2025-12-08/aggregations/load-profiles/dsgrid.

I have tested registering and submitting with success into my own local registry with the commands:

used spark backend with 2 debug nodes and 8x shuffle partition multiplier

spark-submit --master=spark://$(hostname):7077 $(which dsgrid-cli.py) registry projects register-and-submit-dataset --project-id US_DOE_IEF_2025 --dimension-mapping-file /scratch/nreinick/repos/dsgrid-project-IEF/datasets/modeled/transport/dimension_mappings.json5 --log-message "register transport dataset" --data-base-dir /projects/evix/evbps/grid-team-deliverables/ief/2025-12-08/aggregations/load-profiles/dsgrid/ --dataset-config-file /scratch/nreinick/repos/dsgrid-project-IEF/datasets/modeled/transport/dataset.json5 --missing-associations-base-dir /projects/evix/evbps/grid-team-deliverables/ief/2025-12-08/aggregations/load-profiles/dsgrid/

used duckdb backend

dsgrid registry projects register-and-submit-dataset --project-id US_DOE_IEF_2025 --dimension-mapping-file /scratch/nreinick/repos/dsgrid-project-IEF/datasets/modeled/transport_stock/dimension_mappings.json5 --log-message "register transport stock dataset" --data-base-dir /projects/evix/evbps/grid-team-deliverables/ief/2025-12-08/aggregations/load-profiles/dsgrid/ --dataset-config-file /scratch/nreinick/repos/dsgrid-project-IEF/datasets/modeled/transport_stock/dataset.json5 --missing-associations-base-dir /projects/evix/evbps/grid-team-deliverables/ief/2025-12-08/aggregations/load-profiles/dsgrid/

@nreinicke

Copy link
Copy Markdown
Author

@elainethale @daniel-thom @ashreeta - I can't explicitly request your review and so informally tagging you here for a review

@nreinicke

Copy link
Copy Markdown
Author

After spending a little bit more time with the dsgrid docs/code, I modified this to have vehicle stock as it's own metric.

Comment on lines +8 to +10
electricity_ev_ldv_depot_l2,Commercial Light-Duty EV Depot Level 2 Charging,electricity,kWh
electricity_ev_ldv_depot_dcfc,Commercial Light-Duty EV Depot DCFC Charging,electricity,kWh
electricity_ev_ldv_opportunity_dcfc,Commercial Light-Duty EV Opportunity DCFC Charging,electricity,kWh

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice add!

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If this is the same as datasets/modeled/transport/dimension_mappings/county_to_county.csv, you can just point to that file rather than duplicating.

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good point, I just updated to remove the redundant files

from_id,to_id
ief_breakthrough,breakthrough
ief_high,high
ief_high_inefficient_electrification,inefficient

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@ashreeta, maybe our inefficient scenario should instead be high_inefficient?

@ashreeta ashreeta Dec 16, 2025

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'll go with whatever you think is appropriate, a check with the broader team is probably makes sense. Based on the first dataset (Buildings) the current name is 'Inefficient Electrification'. I am not sure Buildings uses the same assumptions as 'high_inefficient'.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Again, if this is the same as the previous one, can just point to that one (../transport/dimensions/counties.csv). You don't have to duplicate.

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Removed in latest commit

@nreinicke

Copy link
Copy Markdown
Author

Just a heads up that by adding the new stock metric, the transport_stock dataset is correctly registering but I'm having issues with the transport dataset, getting the error:

ERROR [dsgrid.cli.common common.py:72] : timed_ failed: exception=DSGInvalidDataset message="Bug: DimensionType.METRIC has multiple base dimensions in the project, dataset ief_2025_transport does not specify a mapping, and dsgrid could not discern which base dimension to use.

What would be the best way to configure these two datasets to properly recognize that the end_use metric is relevant to the transport dataset and the vehicle_stock metric is relevant to the transport_stock dataset and still allow them to share dimensions?

@ashreeta

ashreeta commented Dec 12, 2025

Copy link
Copy Markdown
Collaborator

Hi @nreinicke I think the project dimensions might need to be updated, 2 enduses seem to be missing.(https://github.com/nreinicke/dsgrid-project-IEF/blob/ndr/transport-updates/project/dimensions/enduses.csv) . Also this : (https://github.com/nreinicke/dsgrid-project-IEF/blob/ndr/transport-updates/project/dimensions/subset/subsectors_by_sector.csv) needs to be updated if you want to use subset in the stock dataset.
I don't know the best approach to adding the vehicle stock metric, normally I would just add it to the list in this file (https://github.com/nreinicke/dsgrid-project-IEF/blob/ndr/transport-updates/datasets/modeled/transport/dimensions/enduses.csv) and put in the appropriate name and unit (I think the fuel_id would be 'stock'). Then you could also use the same file for specifying the transportation enduses subset.: (https://github.com/nreinicke/dsgrid-project-IEF/blob/ndr/transport-updates/datasets/modeled/transport/dimensions/enduses.csv).

Recognizing that 'enduses' is just a name here, without further significance. I could have also named the file 'metrics.csv'

@nreinicke

Copy link
Copy Markdown
Author

That sounds good, I've updated the project enduse file to include the new transportation end uses.

Regarding the subsectors_by_sectors file, when you say it needs to be updated, do you mean I should be adding a new sector for the transportation stock?

Lastly, for the stock vehicle metric, would you recommend that I remove the stock dimension from the project and just add it into the enduses file?

@ashreeta

ashreeta commented Dec 15, 2025

Copy link
Copy Markdown
Collaborator

Hi @nreinicke, yes add transportation stock as a new column and put an x for the relevant metrics.
And yes for the stock vehicle metric, I think its simpler to just add it into the enduses file. I think you can still keep it as is if you want to. The bug might be fixed if you add a similar bracketed section specifying the relevant metric for the transportation (regular) dataset as here:https://github.com/nreinicke/dsgrid-project-IEF/blob/98158801240dea86db02fa364f2696d576d44d87/project/project.json5#L211

@elainethale

elainethale commented Dec 15, 2025

Copy link
Copy Markdown
Contributor

Hi @nreinicke, yes add transportation stock as a new column and put an x for the relevant metrics. And yes for the stock vehicle metric, I think its simpler to just add it into the enduses file. I think you can still keep it as is if you want to, but I am not sure how the subsectors_by_sectors would need to be updated, I suppose as long as you add the transportation stock as a new column it should work fine.

@ashreeta, @nreinicke, stock should be a separate dataset. It's units are in no way compatible with enduses.

@ashreeta

Copy link
Copy Markdown
Collaborator

Hi @elainethale yes he does have it as a seperate dataset. However the subset defined in the config is causing an error.

@nreinicke

Copy link
Copy Markdown
Author

@ashreeta - After the latest commit I was able to get both datasets registered and submitted on my end with this script. Let me know if there's anything else needed from my side!

@ashreeta

Copy link
Copy Markdown
Collaborator

perfect, thanks. I'll test it as soon as I can and merge it to main once I can confirm.

@ashreeta ashreeta self-assigned this Dec 19, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants