Skip to content

Project Config

TOML Example (Click to Expand)
################## Project data ####################

[project]
  name = "test1"  # A short name in one word as project identifier
  full_name = "Test Project 1"
  description = "This is the first test project for PIPES using some example data and configs as a test case"
  assumptions = [
    "We can create a test project for the C2C data pipeline.",
    "You can enter any project level assumptions here."
    ]
  scheduled_start = "2022-09-27"
  scheduled_end = "2024-01-01"
  sensitivities = []

  [[project.milestones]]
    name = "Milestone 1"
    description = "First test project milestone"
    milestone_date = "2022-11-01"
  [[project.milestones]]
    name = "Milestone 2"
    description = "Second test project milestone"
    milestone_date = "2022-12-01"

  [project.owner] # who will be the main POC for the project?
    first_name = "Joe"
    last_name = "Shmo"
    email = "joe.shmo@nrel.gov"
    username = "jshmo"

  [project.requirements] # these are default requirements to be used unless otherwise specified at a project run level or for individual models
    weather_years = [2012]
    model_years = [2020, 2025, 2030, 2040, 2045]
    geographic_extent = "City-wide"


  ################# project scenario data ####################

  [[project.scenarios]]
    name = "scenario_1"
    description = [
      "This is a short desscription for Scenario 1."
      ]
  [project.scenarios.other]
    color = "#1BC1AF"

  [[project.scenarios]]
    name = "scenario_2"
    description = [
      "This is a short desscription for Scenario 2."]
  [project.scenarios.other]
    color = "#FA6504"

  [[project.scenarios]]
    name = "scenario_3"
    description = [
      "This is a short desscription for Scenario 3."]
  [project.scenarios.other]
    color = "#5369E5"


  ######## pipeline data ################

  # -------- Run 1 --------
  [[project_runs]]
    name = "1"
    description = "Single scenario, single year, simple test"
    assumptions = ["The single scenario, single year, simple tests assumes 1 scenario and 1 model year at the project run level which is different than the project level. You can enter any assumptions here."]
    scenarios = ["scenario_1"]
    scheduled_start = "2022-09-27"
    scheduled_end = "2022-10-15"

  [project_runs.requirements] # these become the new requirements for all datasets in this run
    model_years = [2020]

  [[project_runs.models]]
    model = "dsgrid"
    type = "Energy Demand" # This is used in pipeline as header to represent the category of model
    description = "The Demand-Side Grid Model used for the example project Run 1"
    assumptions = ["This is a dsgrid assumption"]
    expected_scenarios = ["model_scenario_1"] # scenarios we're expecting the model to checkin datasets under
    scheduled_start = "2022-09-28"
    scheduled_end = "2022-10-05"

  [[project_runs.models.scenario_mappings]] # need to check that either all project scenarios are accounted for or that all project_run scenarios are accounted for if models.scenario_mappings are provided
    model_scenario = "model_scenario_1"
    project_scenarios = ["scenario_1"] # one model scenario can map to multiple project scenarios.
    description = [
      "This is a short description of the scenario mapping."]

  [project_runs.models.requirements]  # model specific requirement that applies to this run
    geographic_extent = "RS-A"

  [[project_runs.models]]
    model = "rpm"
    type = "Capacity Expansion"
    description = "Resource Planning Model for LADWP and WECC from the example project"
    assumptions = ["This is an RPM assumption."]
    expected_scenarios = ["scenario_1"]
    scheduled_start = "2022-10-05"
    scheduled_end = "2022-10-15"

  [project_runs.models.requirements]
    geographic_extent = "RS-C"

  [[project_runs.topology]]
    from_model = "dsgrid"
    to_model = "rpm"

    [[project_runs.topology.handoffs]]
    id = "handoff_id1"
    description = "Description of handoff_id1."
    scheduled_start = ""  # some date
    scheduled_end = "2023-06-30"  # *Required* some date
    notes = ""

    [[project_runs.topology.handoffs]]
    id = "handoff_id2"
    description = "Description of handoff_id2"
    scheduled_start = ""  # some date
    scheduled_end = "2023-07-10"  # *Required* some date
    notes = ""

  # -------- Run 2 --------
  [[project_runs]]
    name = "2"
    description = "full set of scenarios more complex test"
    assumptions = ["The full set of scenarios more complex test includes all project scenarios with two models having their own defintion that requires mappings back to the project level. This project run includes 3 models with more edges."]
    scenarios = [
      "scenario_1",
      "scenario_2",
      "scenario_3",
    ]
    scheduled_start = "2022-10-20"
    scheduled_end = "2023-01-01"

    [project_runs.requirements]
    # Empty, inherits requirements from project

    [[project_runs.models]]
      model = "dsgrid"  # This must be unique
      model_team = "dsgrid"  # *optional* if this isn't provided, the associated model team is looked up via the "model" property above
      display_name = "dsGrid"  # *optional* A display name, if different than "model" property above
      type = "Energy Demand"
      description = "The Demand-Side Grid Model used for PIPES Test Project 1 Run 2"
      expected_scenarios = ["model_scenario_1"]
      scheduled_start = "2022-10-20"
      scheduled_end = "2022-11-15"

      [project_runs.models.requirements]
      # None

      [[project_runs.models.scenario_mappings]]
        model_scenario = "model_scenario_1"
        project_scenarios = ["scenario_1", "scenario_2", "scenario_3"]
        description = [
          "This is a short description of the scenario mapping."]

      [[project_runs.models.scenario_mappings]]
        model_scenario = "model_scenario_2" 
        project_scenarios = ["scenario_1", "scenario_2", "scenario_3"]
        description = [
          "This is a short description of the scenario mapping."]

      [[project_runs.models.scenario_mappings]]
        model_scenario = "model_scenario_3" 
        project_scenarios = ["scenario_3"]
        description = [
          "This is a short description of the scenario mapping."]

      [project_runs.models.requirements]
      # None


    [[project_runs.models]]
      model = "dgen"
      type = "Distributed Generation Adoption"
      description = "The Distributed Generation Model (dGen) - A customer behind-the-meter adoption model for rooftop solar and distributed storage. Used as an example for the test project."
      expected_scenarios = ["model_scenario_2", "model_scenario_3"]
      scheduled_start = "2022-11-15"
      scheduled_end = "2022-11-30"

      [project_runs.models.requirements]
      # None

      [[project_runs.models.scenario_mappings]]
        model_scenario = "model_scenario_2"
        project_scenarios = ["scenario_2", "scenario_1", "scenario_3"]
        description = "This is a short description of the scenario mapping."

      [[project_runs.models.scenario_mappings]]
        model_scenario = "model_scenario_3"
        project_scenarios = ["scenario_1, scenario_2]
        description = "This is a short description of the scenario mapping."

    [[project_runs.models]] # Note: this model does not have any expected scenarios, so that means we expect all project-level scenarios
      model = "rpm"
      type = "Capacity Expansion"
      description = "Resource Planning Model for LADWP and WECC for the example project."
      assumptions = ["Assumptions for the rpm model under Project Run 2."]
      scheduled_start = "2022-11-30"
      scheduled_end = "2023-01-01"

      [project_runs.models.requirements]
      # None

      # Note: no scenario mappings needed because rpm here uses the project scenarios by default

    [[project_runs.topology]]
      from_model = "dsgrid"
      to_model = "rpm"
      [[project_runs.topology.handoffs]]
        id = "handoff_id3"
        description = "This is a short description for handoff_id3"
        scheduled_start = ""  # some date
        scheduled_end = "2023-05-20"  # *Required* some date
        notes = ""

    [[project_runs.topology]]
      from_model = "dsgrid"
      to_model = "dgen"
      [[project_runs.topology.handoffs]]
        id = "handoff_id4"
        description = "This is a short description for handoff_id4."
        scheduled_start = ""  # some date
        scheduled_end = "2023-05-21"  # *Required* some date
        notes = ""

    [[project_runs.topology]]
      from_model = "dgen"
      to_model = "rpm"
      [[project_runs.topology.handoffs]]
        id = "handoff_id5"
        description = "This is a short description for handoff_id5."
        scheduled_start = ""  # some date
        scheduled_end = "2023-09-30"  # *Required* some date
        notes = ""


##################### modeling teams #####################
[[model_teams]]
  name = "dsgrid"

  [[model_teams.members]]
  first_name = "Sam"
  last_name = "Molnar"
  email = "sam.molnar@nrel.gov"
  username = "smolnar"

  [[model_teams.members]]
  first_name = "Meghan"
  last_name = "Mooney"
  email = "Meghan.Mooney@nrel.gov"
  username = "mmooney"

[[model_teams]]
  name = "dgen"

  [[model_teams.members]]
  first_name = "Jianli"
  last_name = "Gu"
  email = "Jianli.Gu@nrel.gov"
  username = "jgu2"

  [[model_teams.members]]
  first_name = "Jacob"
  last_name = "Nunemaker"
  email = "Jacob.Nunemaker@nrel.gov"
  username = "jnunemak"

[[model_teams]]
  name = "rpm"

  [[model_teams.members]]
  first_name = "Kenny"
  last_name = "Gruchalla"
  email = "Kenny.Gruchalla@nrel.gov"
  username = "kgruchal"

  [[model_teams.members]]
  first_name = "David"
  last_name = "Rager"
  email = "David.Rager@nrel.gov"
  username = "drager"

Schema Reference

The Project config initializes the project, including schemas of project, project run, and model requirements/scenarios/assumptions/scheduling.

schemas

ProjectCreate

Project creation schema.

Attributes:

Name Type Description
name str

Human-readable project id name, must be unique.

title str

Project title.

description str

Project description.

assumptions list[str]

Project assumptions.

requirements dict

Project requirements.

scenarios list[Scenario]

Project scenarios.

sensitivities list[Sensitivity]

Project sensitivities.

milestones list[Milestone]

Project milestones.

scheduled_start datetime

Project start datetime, format YYYY-MM-DD.

scheduled_end datetime

Project end datetime, format YYYY-MM-DD.

owner UserCreate

Project owner.

leads set[UserCreate]

List of project leads.

# teams

List of project teams.

Fields:

Validators:

assumptions

project assumptions

description

project description

leads

list of project lead

milestones

project milestones

name

human-readable project id name, must be unique.

owner

project owner

requirements

project requirements

scenarios

project scenarios

scheduled_end

format YYYY-MM-DD

scheduled_start

project start datetime, format YYYY-MM-DD

sensitivities

project sensitivities

title

Project title

Milestone

Project milestone schema.

Attributes:

Name Type Description
name str

Milestone name must be unique from each other.

description str

Description of milestone.

milestone_date datetime

Format YYYY-MM-DD, it must be within the dates of the project.

Fields:

Validators:

description

description of milestone

milestone_date

format YYYY-MM-DD, it must be within the dates of the project.

name

milestone name must be unique from each other.

Scenario

Project scenario schema.

Attributes:

Name Type Description
name str

Scenario name.

description list[str]

Scenario description.

other dict

Other properties applied to scenario.

Fields:

Validators:

description

scenario description

name

scenario name

other

other properties applied to scenario

Sensitivity

Project sensitivity schema.

Attributes:

Name Type Description
name str

Sensitivity name.

description list[str]

Sensitivity description.

Fields:

Validators:

description

sensitivity description

name

sensitivity name

schemas

ProjectRunCreate

Project run creation schema.

Attributes:

Name Type Description
name str

Project run name.

description str

The description of this project run.

assumptions list[str]

Assumptions associated with project run that differ from project.

requirements dict

Requirements of the project run that differ from the project.

scenarios list[str]

The scenarios of this project run.

scheduled_start datetime

Schedule project run start date in YYYY-MM-DD format.

scheduled_end datetime

Schedule project run end date in YYYY-MM-DD format.

Fields:

Validators:

assumptions

Assumptions associated with project run that differ from project

description

the description of this project run

name

Project run name

requirements

Requirements of the project run that differ from the project

scenarios

the scenarios of this prject run

scheduled_end

Schedule project run end date in YYYY-MM-DD format

scheduled_start

Schedule project run start date in YYYY-MM-DD format

Model

ModelCreate

Model schema.

Attributes:

Name Type Description
name str

The model name.

display_name str | None

Display name for this model.

type str

Type of model to use in graphic headers (e.g, 'Capacity Expansion').

description str | list[str]

Description of the model.

modeling_team str

Which modeling team to link this model to.

assumptions list[str]

List of model assumptions.

requirements dict

Model specific requirements (if different from Project and Project-Run).

scheduled_start datetime

Schedule model start date in YYYY-MM-DD format.

scheduled_end datetime

Schedule model end date in YYYY-MM-DD format.

expected_scenarios list[str]

List of expected model scenarios.

scenario_mappings list[ScenarioMapping]

Model scenarios (if different) and how they map to the project scenarios.

other dict

Other metadata info about the model in dictionary.

Fields:

Validators:

assumptions

List of model assumptions

description

Description of the model

display_name

Display name for this model.

expected_scenarios

List of expected model scenarios

modeling_team

Which modeling team to link this model to.

name

the model name

other

other metadata info about the model in dictionary

requirements

Model specific requirements (if different from Project and Project-Run)

scenario_mappings

Model scenarios (if different) and how they map to the project scenarios

scheduled_end

Schedule model end date in YYYY-MM-DD format

scheduled_start

Schedule model start date in YYYY-MM-DD format

type

Type of model to use in graphic headers (e.g, 'Capacity Expansion')

ScenarioMapping

Mapping model scenario to project scenarios.

Attributes:

Name Type Description
model_scenario str

The model scenario name.

project_scenarios list[str]

List of project scenario names that the model scenario maps to.

description list[str]

Model scenario description.

other dict

Other metadata info about the model scenario mapping in dictionary.

Config:

  • protected_namespaces: ()

Fields:

Validators:

description

Model scenario description

model_scenario

The model scenario name

other

other metadata info about the model scenario mapping in dictionary

project_scenarios

List of project scenario names that the model scenario maps to

schemas

TeamCreate

Team creation schema.

Attributes:

Name Type Description
name str

The team name.

description str | None

The team description.

members list[UserCreate]

List of users.

Config:

  • default: {'json_schema_extra': {'examples': [{'name': 'team1', 'description': 'this is team one', 'members': [{'email': 'user1@example.com', 'first_name': 'User1', 'last_name': 'Test', 'organization': 'Org1'}, {'email': 'user2@example.com', 'first_name': 'User2', 'last_name': 'Test', 'organization': 'Org2'}]}]}}

Fields:

description

The team description

members

List of users

name

The team name

schemas

UserCreate

User base model.

Attributes:

Name Type Description
email EmailStr

Email address.

first_name str | None

First name.

last_name str | None

Last name.

organization str | None

Organization name.

Fields:

email

Email address

first_name

First name

last_name

Last name

organization

Organization name