Add ability to instantiate a Scenario object via paths to relevant files
@jenhagg がすでに取り組んでいます。
2021年4月2日 から。
評価
この issue はまだ評価されていません。
説明
Motivation/Description
As discussed over Slack, a Scenario in Analyze state is mostly read-only (with the exception of being able to delete the Scenario), providing access to:
- scenario metadata that's retrieved from the ScenarioList
- a Grid object that's parsed from a .mat file
- input profiles
- output time series
- a change table
Instantiating a Scenario in Analyze state currently relies on using the ScenarioList on the 'compute server' to grab the metadata, locate the grid.mat file, locate the output files, and calculate the input profiles from the base profiles and the change table. However, if we can instantiate a Scenario object in an alternate way that still provides the user with access to all of the relevant data, then we can pass this Scenario object to the many analysis and plotting functions in PostREISE without depending on an external machine that has a ScenarioList and organizes the input/output files in a particular way. This could allow alternate organization of the input/output files to suit a user's needs, e.g. all files for one scenario in the same folder rather than named in a particular way in a raw folder, a data/input folder, a data/output folder.
One design idea
We could create a new AnalyzeFromFilepaths class, as a child class of the existing Analyze class (so that all of our existing checks on isinstance(foo, Analyze) still pass. This new class would overwrite all existing get_x() methods.
Similarly, we could create a new ScenarioFromFilepaths class as a child class of the existing Scenario class. We could instantiate this new ScenarioFromFilepaths class in the following pattern:
class Scenario:
...
@staticmethod
def from_filepaths(
*,
grid_model,
interconnect,
grid_filepath,
pg_filepath,
pf_filepath,
lmp_filepath,
congu_filepath,
congl_filepath,
averaged_cong_filepath,
dcline_pf_filepath=None,
storage_pg_filepath=None,
storage_e_filepath=None,
load_shed_filepath=None,
demand_filepath=None,
hydro_filepath=None,
solar_filepath=None,
wind_filepath=None,
base_demand_filepath=None,
base_hydro_filepath=None,
base_solar_filepath=None,
base_wind_filepath=None,
ct=None,
)
Then, a Scenario which behaves virtually-identically identically to the current Scenario in Analyze state (with the exception of being able to access certain ScenarioList entries) could be instantiated with:
- All required inputs, plus
- either:
- paths to scaled/appended input profiles, or
- paths to base input profiles, plus a change table
with the call signature scenario = Scenario.from_filepaths(**kwargs).
This could also provide the base for functions which could be given one or more folders (e.g. outputs_folder, inputs_folder or base_profiles_folder + ct) and would determine the filepaths automatically and return a ScenarioFromFilepaths.
- 主要言語
- Python
- スター
- 64
- フォーク
- 48
- PR マージ指標
- 30日以内にマージされた PR はありません
環境構築
- Dockerfile または Docker Compose ファイルあり
- プルリクエストのテンプレートなし
- コントリビューションガイドなし
はじめの一歩
- issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
- 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
- リポジトリをフォークし、ブランチを切って変更します。
- issue 番号を参照したプルリクエストを送ります。
Breakthrough-Energy/PowerSimData のほかの issue
-
Update demand flexibility documentation再び着手できるかも @jenhagg が 1421 日前に担当しましたが、オープン中のプルリクエストはありません。 オープンdocumentation
Breakthrough-Energy/PowerSimData#706 · 担当者 4 名 ·
-
Allow demand flexibility to be enabled without flexibility profiles再び着手できるかも @jenhagg が 1421 日前に担当しましたが、オープン中のプルリクエストはありません。 オープン
Breakthrough-Energy/PowerSimData#705 · コメント 1 件 · 担当者 4 名 ·
-
Create a dedicated object that compares two grids再び着手できるかも @jenhagg が 1484 日前に担当しましたが、オープン中のプルリクエストはありません。 オープンfeature request
Breakthrough-Energy/PowerSimData#688 · 担当者 4 名 ·
-
Fetch usa_tamu data from zenodo再び着手できるかも @jenhagg が 1485 日前に担当しましたが、オープン中のプルリクエストはありません。 オープンfeature request
Breakthrough-Energy/PowerSimData#687 · 担当者 4 名 ·
-
Make ramp rate input flexible to other grids再び着手できるかも @jenhagg が 1496 日前に担当しましたが、オープン中のプルリクエストはありません。 オープンbug
Breakthrough-Energy/PowerSimData#680 · コメント 9 件 · 担当者 5 名 ·
Breakthrough-Energy/PowerSimData の issue をすべて見る
似ている issue
-
[Bug] Unit tests reach real Bedrock call paths without patching the model対応中かも @proton0210 が今日担当しました。 オープンbug
難易度 2/5 1〜3時間 初心者へのやさしさ 67/100
aws-samples/sample-aws-genai-db-modernizer#1318 · コメント 1 件 ·
メンテナーはふだん 1 日以内に返信
-
pyarrow-25.0.1-cp310-cp310-manylinux_2_28_x86_64.whl: 1 vulnerabilities (highest severity is: 5.3)オープンMend: dependency security vulnerability
難易度 2/5 1〜3時間 初心者へのやさしさ 62/100
capitalone/locopy#394 ·
-
[Bug] Unhandled ValueError terminates watchdog thread when GISRC value contains multiple colonsオープンbug
難易度 2/5 1〜3時間 初心者へのやさしさ 76/100
メンテナーはふだん 1 日以内に返信
-
sdk-typescript: unquoted COPY globs in shell form are silently dropped from the image build contextオープンbug javascript
難易度 2/5 1〜3時間 初心者へのやさしさ 78/100
メンテナーはふだん 1 日以内に返信
-
enhancement
難易度 2/5 1〜3時間 初心者へのやさしさ 65/100
ietf-tools/datatracker#11922 · コメント 1 件 ·
メンテナーはふだん 1 日以内に返信