Skip to content

Add some RecipeRule documentation#1283

Merged
David-Baddeley merged 2 commits into
python-microscopy:masterfrom
zacsimile:reciperule-docs
Sep 26, 2022
Merged

Add some RecipeRule documentation#1283
David-Baddeley merged 2 commits into
python-microscopy:masterfrom
zacsimile:reciperule-docs

Conversation

@zacsimile
Copy link
Copy Markdown
Member

Some documentation for RecipeRules, based on recent experiences. Probably this belongs in docs/cluster/programatic_usage.rst from #1281, rather than in its own rules.rst.

Comment thread docs/cluster/rules.rst Outdated
Note that in this case, only a single file is passed as the input shape.
However, the server expects a list and therefore treats the input name
``shape`` as a stub. In the event only a single input is in the list,
the input is named ``shape_shape`` (stub followed by stub).
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

This is incorrect - the <input_name>_<table_name> pattern only applies to HDF files which can contain multiple data tables (ie you can't assume that an HDF only contains a single table), and has nothing to do with whether the inputs is a list or not.

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

Good to know. I took a guess on this one because I couldn't find where it maps the name. Where does the <input_name>_<table_name> bit happen?

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Recipe._inject_tables_from_hdf5() (line 558 of recipe.py). Looking at the code there, if you use the 'input' as the key to the rule etc ... it will just inject with the table name.

@David-Baddeley David-Baddeley merged commit ff9afc2 into python-microscopy:master Sep 26, 2022
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.

2 participants