PolicyEngine / PolicyEngine/state-legislative-tracker
Migrate impact computation off split state H5 files
Nobody has claimed this yet.
- Dominant language
- JavaScript
- Stars
- 0
- Forks
- 2
- PR merge metrics
- No merged PRs in 30d
Description
Populace US releases are moving to a single national populace_us_2024.h5 plus region scoping, so this repo should stop downloading policyengine-us-data/states/{STATE}.h5 in scripts/compute_impacts.py.
Current references:
scripts/compute_impacts.py:get_state_dataset()downloadsstates/{STATE}.h5frompolicyengine/policyengine-us-data..claude/commands/score-bill.mddocuments the same state-specific dataset path.
Expected migration:
- Use the certified national Populace dataset and scope by
state_fips/congressional_district_geoidthroughpolicyengine.pyregion scoping, or a shared helper that preserves equivalent semantics. - Do not synthesize one-H5-per-state or one-H5-per-district URLs.
- Keep district calculations based on the national file's
congressional_district_geoidsupport.
Note: the current local checkout has active uncommitted work on add-manifold-markets, so I did not patch it in place.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with get_state_dataset() in scripts/compute_impacts.py and compare its dataset selection with the path documented in .claude/commands/score-bill.md. Trace how policyengine.py applies region scoping, then migrate both references to the certified national dataset while preserving state_fips and congressional_district_geoid calculations. Done means no state- or district-specific H5 URLs remain and district calculations use the national file.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- python
- Domain
- data
- Issue type
- Refactor
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Quiet
- Clarity
- Mostly clear
- Newbie friendliness
- 48/100