You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Clean Up create_empty_ts.smk for Unused Components
Description
The create_empty_ts.smk rule currently writes empty_ts for all components that require foreign_key='efficiency', even if those components are not listed in model_structure["components"]. While this behavior does not break functionality, it is not clean and can be misleading.
To improve clarity and maintainability, this behavior should be revised.
Steps to Take
Filter foreign_keys_efficiency to exclude components not listed in model_structure["components"], following the approach used for foreign_keys_profile:
# Drop the ones that are not listed in model_structureforeign_keys_efficiency= [
fkforfkinforeign_keys_efficiencyiffk["efficiency"].split("-efficiency")[0]
inmodel_structure["components"]
]
Ensure that empty_ts_load, empty_ts_feedin, and empty_ts_efficiency can gracefully handle being empty dataframes when applicable.
Error Message Log
WARNING - Waiting at most 5 seconds for missing files.
MissingOutputException in rule create_empty_ts in file [...]/apipe/esys/snakemake_rules/create_empty_ts.smk, line 1:
Job 0 completed successfully, but some output files are missing. Missing files after 5 seconds. This might be due to filesystem latency. If that is the case, consider to increase the wait time with --latency-wait:
store/datasets/esys_raw/data/time_series/empty_ts_efficiencies.csv
Removing output files of failed job create_empty_ts since they might be corrupted:
store/datasets/esys_raw/data/time_series/empty_ts_load.csv, store/datasets/esys_raw/data/time_series/empty_ts_feedin.csv
WARNING - Removing output files of failed job create_empty_ts since they might be corrupted:
store/datasets/esys_raw/data/time_series/empty_ts_load.csv, store/datasets/esys_raw/data/time_series/empty_ts_feedin.csv
Shutting down, this might take some time.
WARNING - Shutting down, this might take some time.
Exiting because a job execution failed. Look above for error message
Complete log: .snakemake/log/2024-11-28T134931.620653.snakemake.log
WARNING - Complete log: .snakemake/log/2024-11-28T134931.620653.snakemake.log
Acceptance Criteria
create_empty_ts.smk no longer writes empty_ts files for components not listed in model_structure["components"].
empty_ts_load, empty_ts_feedin, and empty_ts_efficiency can remain valid but empty when appropriate.
The pipeline runs cleanly without warnings or unnecessary outputs.
The text was updated successfully, but these errors were encountered:
Clean Up
create_empty_ts.smk
for Unused ComponentsDescription
The
create_empty_ts.smk
rule currently writesempty_ts
for all components that requireforeign_key='efficiency'
, even if those components are not listed inmodel_structure["components"]
. While this behavior does not break functionality, it is not clean and can be misleading.To improve clarity and maintainability, this behavior should be revised.
Steps to Take
foreign_keys_efficiency
to exclude components not listed inmodel_structure["components"]
, following the approach used forforeign_keys_profile
:empty_ts_load
,empty_ts_feedin
, andempty_ts_efficiency
can gracefully handle being empty dataframes when applicable.Error Message Log
WARNING - Waiting at most 5 seconds for missing files.
MissingOutputException in rule create_empty_ts in file [...]/apipe/esys/snakemake_rules/create_empty_ts.smk, line 1:
Job 0 completed successfully, but some output files are missing. Missing files after 5 seconds. This might be due to filesystem latency. If that is the case, consider to increase the wait time with --latency-wait:
store/datasets/esys_raw/data/time_series/empty_ts_efficiencies.csv
Removing output files of failed job create_empty_ts since they might be corrupted:
store/datasets/esys_raw/data/time_series/empty_ts_load.csv, store/datasets/esys_raw/data/time_series/empty_ts_feedin.csv
WARNING - Removing output files of failed job create_empty_ts since they might be corrupted:
store/datasets/esys_raw/data/time_series/empty_ts_load.csv, store/datasets/esys_raw/data/time_series/empty_ts_feedin.csv
Shutting down, this might take some time.
WARNING - Shutting down, this might take some time.
Exiting because a job execution failed. Look above for error message
Complete log: .snakemake/log/2024-11-28T134931.620653.snakemake.log
WARNING - Complete log: .snakemake/log/2024-11-28T134931.620653.snakemake.log
Acceptance Criteria
create_empty_ts.smk
no longer writesempty_ts
files for components not listed inmodel_structure["components"]
.empty_ts_load
,empty_ts_feedin
, andempty_ts_efficiency
can remain valid but empty when appropriate.The text was updated successfully, but these errors were encountered: