-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
fb0b26d
commit f96520b
Showing
2 changed files
with
27 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
26 changes: 26 additions & 0 deletions
26
src/depiction_targeted_preproc/workflow/rules/rules_panel.smk
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
"""This file bundles all panel manipulation rules needed throughout the pipeline. | ||
To keep things tidy, each file will be in the same directory `{sample}/panels/`. | ||
Initially before the workflow is started a file `mass_list.raw.csv` has to be created. | ||
""" | ||
|
||
|
||
rule panel_standardized_full: | ||
input: | ||
csv="{sample}/panels/unstandardized_full.csv", | ||
output: | ||
csv="{sample}/panels/full.csv", | ||
shell: | ||
"python -m depiction_targeted_preproc.workflow.panel.standardize_panel " | ||
"--input-panel-path {input.csv} --config-name standardize_main_config.yml " | ||
"--output-panel-path {output.csv}" | ||
|
||
|
||
rule panel_filter_calibration: | ||
input: | ||
csv="{sample}/panels/full.csv", | ||
output: | ||
csv="{sample}/panels/calibration.csv", | ||
run: | ||
import polars as pl | ||
|
||
pl.read_csv(input.csv).filter(type="target").write_csv(output.csv) |