Skip to content

Sampling regions characteristic#1418

Draft
afontani wants to merge 48 commits into
developfrom
sampling_regions
Draft

Sampling regions characteristic#1418
afontani wants to merge 48 commits into
developfrom
sampling_regions

Conversation

@afontani

@afontani afontani commented May 27, 2025

Copy link
Copy Markdown
Contributor

Pull Request Description

Add the sampling region characteristic ahead of the geographic resolution refactor.
CEC Climate zone is modified slightly: By assigning a climate zone to a census tract. Census tracts with multiple CEC climate zones are assigned to the climate zone with the largest number of units. This has little impact, there is some small changes to the distributions ~3% in some County and PUMAs in California.

Related Pull Requests

https://github.com/NREL/resstock-estimation/pull/463

Related Issues

  • Round Ground Thermal Conductivity option Option=2.0 to Option=2. Excel often replaces 2.0 with 2 and causes a diff in resstock that makes CI fail. Rounding it to be an integer avoids this from happening.

Checklist

Required:

Optional (not all items may apply):

@afontani afontani self-assigned this Jun 11, 2025
@rajeee rajeee mentioned this pull request Aug 20, 2025
12 tasks
@joseph-robertson joseph-robertson assigned rajeee and unassigned afontani Aug 21, 2025
Base automatically changed from latest-os-hpxml to develop October 29, 2025 16:29
The New Stratified Sampler supports the new sampling method under development in ResStock.
Joe Robertson and others added 15 commits June 9, 2026 13:02
The `sampler.py` module was recently renamed to `run_sampler.py`. This commit updates the `resstock-sampler` script definition in `pyproject.toml` to correctly point to the `main` function within the new `run_sampler` module.
Replaces a hardcoded magic number and a repeated configuration lookup with a single `num_samples_per_segment` variable. This ensures the limit for rows per group consistently matches the configured or default value, improving clarity and maintainability.
random.seed(42)


def test_get_samples() -> None:

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Is this file actually being run on the ci? It looks like maybe not.

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

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.

5 participants