Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
82 changes: 41 additions & 41 deletions notebooks/deepdive.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -1897,18 +1897,18 @@
{
"data": {
"text/plain": [
"\u001b[0;31mType:\u001b[0m property\n",
"\u001b[0;31mString form:\u001b[0m <property object at 0x1326a60c0>\n",
"\u001b[0;31mSource:\u001b[0m \n",
"\u001b[0;31m# pwf.standard_nodes.If.emitting_channels.fget\u001b[0m\u001b[0;34m\u001b[0m\n",
"\u001b[0;34m\u001b[0m\u001b[0;34m@\u001b[0m\u001b[0mproperty\u001b[0m\u001b[0;34m\u001b[0m\n",
"\u001b[0;34m\u001b[0m\u001b[0;32mdef\u001b[0m \u001b[0memitting_channels\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0mself\u001b[0m\u001b[0;34m)\u001b[0m \u001b[0;34m->\u001b[0m \u001b[0mtuple\u001b[0m\u001b[0;34m[\u001b[0m\u001b[0mOutputSignal\u001b[0m\u001b[0;34m]\u001b[0m\u001b[0;34m:\u001b[0m\u001b[0;34m\u001b[0m\n",
"\u001b[0;34m\u001b[0m \u001b[0;32mif\u001b[0m \u001b[0mself\u001b[0m\u001b[0;34m.\u001b[0m\u001b[0moutputs\u001b[0m\u001b[0;34m.\u001b[0m\u001b[0mtruth\u001b[0m\u001b[0;34m.\u001b[0m\u001b[0mvalue\u001b[0m \u001b[0;32mis\u001b[0m \u001b[0mNOT_DATA\u001b[0m\u001b[0;34m:\u001b[0m\u001b[0;34m\u001b[0m\n",
"\u001b[0;34m\u001b[0m \u001b[0;32mreturn\u001b[0m \u001b[0msuper\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m.\u001b[0m\u001b[0memitting_channels\u001b[0m\u001b[0;34m\u001b[0m\n",
"\u001b[0;34m\u001b[0m \u001b[0;32melif\u001b[0m \u001b[0mself\u001b[0m\u001b[0;34m.\u001b[0m\u001b[0moutputs\u001b[0m\u001b[0;34m.\u001b[0m\u001b[0mtruth\u001b[0m\u001b[0;34m.\u001b[0m\u001b[0mvalue\u001b[0m\u001b[0;34m:\u001b[0m\u001b[0;34m\u001b[0m\n",
"\u001b[0;34m\u001b[0m \u001b[0;32mreturn\u001b[0m \u001b[0;34m(\u001b[0m\u001b[0;34m*\u001b[0m\u001b[0msuper\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m.\u001b[0m\u001b[0memitting_channels\u001b[0m\u001b[0;34m,\u001b[0m \u001b[0mself\u001b[0m\u001b[0;34m.\u001b[0m\u001b[0msignals\u001b[0m\u001b[0;34m.\u001b[0m\u001b[0moutput\u001b[0m\u001b[0;34m.\u001b[0m\u001b[0mtrue\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m\u001b[0m\n",
"\u001b[0;34m\u001b[0m \u001b[0;32melse\u001b[0m\u001b[0;34m:\u001b[0m\u001b[0;34m\u001b[0m\n",
"\u001b[0;34m\u001b[0m \u001b[0;32mreturn\u001b[0m \u001b[0;34m(\u001b[0m\u001b[0;34m*\u001b[0m\u001b[0msuper\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m.\u001b[0m\u001b[0memitting_channels\u001b[0m\u001b[0;34m,\u001b[0m \u001b[0mself\u001b[0m\u001b[0;34m.\u001b[0m\u001b[0msignals\u001b[0m\u001b[0;34m.\u001b[0m\u001b[0moutput\u001b[0m\u001b[0;34m.\u001b[0m\u001b[0mfalse\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m"
"\u001B[0;31mType:\u001B[0m property\n",
"\u001B[0;31mString form:\u001B[0m <property object at 0x1326a60c0>\n",
"\u001B[0;31mSource:\u001B[0m \n",
"\u001B[0;31m# pwf.standard_nodes.If.emitting_channels.fget\u001B[0m\u001B[0;34m\u001B[0m\n",
"\u001B[0;34m\u001B[0m\u001B[0;34m@\u001B[0m\u001B[0mproperty\u001B[0m\u001B[0;34m\u001B[0m\n",
"\u001B[0;34m\u001B[0m\u001B[0;32mdef\u001B[0m \u001B[0memitting_channels\u001B[0m\u001B[0;34m(\u001B[0m\u001B[0mself\u001B[0m\u001B[0;34m)\u001B[0m \u001B[0;34m->\u001B[0m \u001B[0mtuple\u001B[0m\u001B[0;34m[\u001B[0m\u001B[0mOutputSignal\u001B[0m\u001B[0;34m]\u001B[0m\u001B[0;34m:\u001B[0m\u001B[0;34m\u001B[0m\n",
"\u001B[0;34m\u001B[0m \u001B[0;32mif\u001B[0m \u001B[0mself\u001B[0m\u001B[0;34m.\u001B[0m\u001B[0moutputs\u001B[0m\u001B[0;34m.\u001B[0m\u001B[0mtruth\u001B[0m\u001B[0;34m.\u001B[0m\u001B[0mvalue\u001B[0m \u001B[0;32mis\u001B[0m \u001B[0mNOT_DATA\u001B[0m\u001B[0;34m:\u001B[0m\u001B[0;34m\u001B[0m\n",
"\u001B[0;34m\u001B[0m \u001B[0;32mreturn\u001B[0m \u001B[0msuper\u001B[0m\u001B[0;34m(\u001B[0m\u001B[0;34m)\u001B[0m\u001B[0;34m.\u001B[0m\u001B[0memitting_channels\u001B[0m\u001B[0;34m\u001B[0m\n",
"\u001B[0;34m\u001B[0m \u001B[0;32melif\u001B[0m \u001B[0mself\u001B[0m\u001B[0;34m.\u001B[0m\u001B[0moutputs\u001B[0m\u001B[0;34m.\u001B[0m\u001B[0mtruth\u001B[0m\u001B[0;34m.\u001B[0m\u001B[0mvalue\u001B[0m\u001B[0;34m:\u001B[0m\u001B[0;34m\u001B[0m\n",
"\u001B[0;34m\u001B[0m \u001B[0;32mreturn\u001B[0m \u001B[0;34m(\u001B[0m\u001B[0;34m*\u001B[0m\u001B[0msuper\u001B[0m\u001B[0;34m(\u001B[0m\u001B[0;34m)\u001B[0m\u001B[0;34m.\u001B[0m\u001B[0memitting_channels\u001B[0m\u001B[0;34m,\u001B[0m \u001B[0mself\u001B[0m\u001B[0;34m.\u001B[0m\u001B[0msignals\u001B[0m\u001B[0;34m.\u001B[0m\u001B[0moutput\u001B[0m\u001B[0;34m.\u001B[0m\u001B[0mtrue\u001B[0m\u001B[0;34m)\u001B[0m\u001B[0;34m\u001B[0m\n",
"\u001B[0;34m\u001B[0m \u001B[0;32melse\u001B[0m\u001B[0;34m:\u001B[0m\u001B[0;34m\u001B[0m\n",
"\u001B[0;34m\u001B[0m \u001B[0;32mreturn\u001B[0m \u001B[0;34m(\u001B[0m\u001B[0;34m*\u001B[0m\u001B[0msuper\u001B[0m\u001B[0;34m(\u001B[0m\u001B[0;34m)\u001B[0m\u001B[0;34m.\u001B[0m\u001B[0memitting_channels\u001B[0m\u001B[0;34m,\u001B[0m \u001B[0mself\u001B[0m\u001B[0;34m.\u001B[0m\u001B[0msignals\u001B[0m\u001B[0;34m.\u001B[0m\u001B[0moutput\u001B[0m\u001B[0;34m.\u001B[0m\u001B[0mfalse\u001B[0m\u001B[0;34m)\u001B[0m\u001B[0;34m\u001B[0m\u001B[0;34m\u001B[0m\u001B[0m"
]
},
"metadata": {},
Expand Down Expand Up @@ -2634,34 +2634,34 @@
{
"data": {
"text/plain": [
"\u001b[0;31mSignature:\u001b[0m \u001b[0mRunnable\u001b[0m\u001b[0;34m.\u001b[0m\u001b[0m_parse_executor\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0mexecutor\u001b[0m\u001b[0;34m)\u001b[0m \u001b[0;34m->\u001b[0m \u001b[0;34m'StdLibExecutor'\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n",
"\u001b[0;31mSource:\u001b[0m \n",
" \u001b[0;34m@\u001b[0m\u001b[0mstaticmethod\u001b[0m\u001b[0;34m\u001b[0m\n",
"\u001b[0;34m\u001b[0m \u001b[0;32mdef\u001b[0m \u001b[0m_parse_executor\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0mexecutor\u001b[0m\u001b[0;34m)\u001b[0m \u001b[0;34m->\u001b[0m \u001b[0mStdLibExecutor\u001b[0m\u001b[0;34m:\u001b[0m\u001b[0;34m\u001b[0m\n",
"\u001b[0;34m\u001b[0m \u001b[0;34m\"\"\"\u001b[0m\n",
"\u001b[0;34m We may want to allow users to specify how to build an executor rather than\u001b[0m\n",
"\u001b[0;34m actually providing an executor instance -- so here we can interpret these.\u001b[0m\n",
"\u001b[0;34m\u001b[0m\n",
"\u001b[0;34m NOTE:\u001b[0m\n",
"\u001b[0;34m `concurrent.futures.Executor` _won't_ actually work, because we need\u001b[0m\n",
"\u001b[0;34m stuff with :mod:`cloudpickle` support. We're leaning on this for a guaranteed\u001b[0m\n",
"\u001b[0;34m interface (has `submit` and returns a `Future`), and leaving it to the user\u001b[0m\n",
"\u001b[0;34m to provide an executor that will actually work!!!\u001b[0m\n",
"\u001b[0;34m\u001b[0m\n",
"\u001b[0;34m NOTE:\u001b[0m\n",
"\u001b[0;34m If, in the future, this parser is extended to instantiate new executors from\u001b[0m\n",
"\u001b[0;34m instructions, these new instances may not be caught by the\u001b[0m\n",
"\u001b[0;34m `executor_shutdown` method. This will require some re-engineering to make\u001b[0m\n",
"\u001b[0;34m sure we don't have dangling executors.\u001b[0m\n",
"\u001b[0;34m \"\"\"\u001b[0m\u001b[0;34m\u001b[0m\n",
"\u001b[0;34m\u001b[0m \u001b[0;32mif\u001b[0m \u001b[0misinstance\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0mexecutor\u001b[0m\u001b[0;34m,\u001b[0m \u001b[0mStdLibExecutor\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m:\u001b[0m\u001b[0;34m\u001b[0m\n",
"\u001b[0;34m\u001b[0m \u001b[0;32mreturn\u001b[0m \u001b[0mexecutor\u001b[0m\u001b[0;34m\u001b[0m\n",
"\u001b[0;34m\u001b[0m \u001b[0;32melse\u001b[0m\u001b[0;34m:\u001b[0m\u001b[0;34m\u001b[0m\n",
"\u001b[0;34m\u001b[0m \u001b[0;32mraise\u001b[0m \u001b[0mNotImplementedError\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0;34m\u001b[0m\n",
"\u001b[0;34m\u001b[0m \u001b[0;34mf\"Expected an instance of {StdLibExecutor}, but got {executor}.\"\u001b[0m\u001b[0;34m\u001b[0m\n",
"\u001b[0;34m\u001b[0m \u001b[0;34m)\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n",
"\u001b[0;31mFile:\u001b[0m ~/work/pyiron/pyiron_workflow/pyiron_workflow/mixin/run.py\n",
"\u001b[0;31mType:\u001b[0m function"
"\u001B[0;31mSignature:\u001B[0m \u001B[0mRunnable\u001B[0m\u001B[0;34m.\u001B[0m\u001B[0m_parse_executor\u001B[0m\u001B[0;34m(\u001B[0m\u001B[0mexecutor\u001B[0m\u001B[0;34m)\u001B[0m \u001B[0;34m->\u001B[0m \u001B[0;34m'StdLibExecutor'\u001B[0m\u001B[0;34m\u001B[0m\u001B[0;34m\u001B[0m\u001B[0m\n",
"\u001B[0;31mSource:\u001B[0m \n",
" \u001B[0;34m@\u001B[0m\u001B[0mstaticmethod\u001B[0m\u001B[0;34m\u001B[0m\n",
"\u001B[0;34m\u001B[0m \u001B[0;32mdef\u001B[0m \u001B[0m_parse_executor\u001B[0m\u001B[0;34m(\u001B[0m\u001B[0mexecutor\u001B[0m\u001B[0;34m)\u001B[0m \u001B[0;34m->\u001B[0m \u001B[0mStdLibExecutor\u001B[0m\u001B[0;34m:\u001B[0m\u001B[0;34m\u001B[0m\n",
"\u001B[0;34m\u001B[0m \u001B[0;34m\"\"\"\u001B[0m\n",
"\u001B[0;34m We may want to allow users to specify how to build an executor rather than\u001B[0m\n",
"\u001B[0;34m actually providing an executor instance -- so here we can interpret these.\u001B[0m\n",
"\u001B[0;34m\u001B[0m\n",
"\u001B[0;34m NOTE:\u001B[0m\n",
"\u001B[0;34m `concurrent.futures.Executor` _won't_ actually work, because we need\u001B[0m\n",
"\u001B[0;34m stuff with :mod:`cloudpickle` support. We're leaning on this for a guaranteed\u001B[0m\n",
"\u001B[0;34m interface (has `submit` and returns a `Future`), and leaving it to the user\u001B[0m\n",
"\u001B[0;34m to provide an executor that will actually work!!!\u001B[0m\n",
"\u001B[0;34m\u001B[0m\n",
"\u001B[0;34m NOTE:\u001B[0m\n",
"\u001B[0;34m If, in the future, this parser is extended to instantiate new executors from\u001B[0m\n",
"\u001B[0;34m instructions, these new instances may not be caught by the\u001B[0m\n",
"\u001B[0;34m `executor_shutdown` method. This will require some re-engineering to make\u001B[0m\n",
"\u001B[0;34m sure we don't have dangling executors.\u001B[0m\n",
"\u001B[0;34m \"\"\"\u001B[0m\u001B[0;34m\u001B[0m\n",
"\u001B[0;34m\u001B[0m \u001B[0;32mif\u001B[0m \u001B[0misinstance\u001B[0m\u001B[0;34m(\u001B[0m\u001B[0mexecutor\u001B[0m\u001B[0;34m,\u001B[0m \u001B[0mStdLibExecutor\u001B[0m\u001B[0;34m)\u001B[0m\u001B[0;34m:\u001B[0m\u001B[0;34m\u001B[0m\n",
"\u001B[0;34m\u001B[0m \u001B[0;32mreturn\u001B[0m \u001B[0mexecutor\u001B[0m\u001B[0;34m\u001B[0m\n",
"\u001B[0;34m\u001B[0m \u001B[0;32melse\u001B[0m\u001B[0;34m:\u001B[0m\u001B[0;34m\u001B[0m\n",
"\u001B[0;34m\u001B[0m \u001B[0;32mraise\u001B[0m \u001B[0mNotImplementedError\u001B[0m\u001B[0;34m(\u001B[0m\u001B[0;34m\u001B[0m\n",
"\u001B[0;34m\u001B[0m \u001B[0;34mf\"Expected an instance of {StdLibExecutor}, but got {executor}.\"\u001B[0m\u001B[0;34m\u001B[0m\n",
"\u001B[0;34m\u001B[0m \u001B[0;34m)\u001B[0m\u001B[0;34m\u001B[0m\u001B[0;34m\u001B[0m\u001B[0m\n",
"\u001B[0;31mFile:\u001B[0m ~/work/pyiron/pyiron_workflow/pyiron_workflow/mixin/run.py\n",
"\u001B[0;31mType:\u001B[0m function"
]
},
"metadata": {},
Expand Down Expand Up @@ -4112,7 +4112,7 @@
"source": [
"## Storage interfaces\n",
"\n",
"We saw in `quickstart.ipynb` how to save and load nodes to/from their default location (based on the current working directory and their semantic label), and how to use checkpointing and autoloading with the built-in `\"pickle\"` storage back end.\n",
"We saw in `quickstart.ipynb` how to save and load nodes to/from their default location (based on the current working directory and their lexical label), and how to use checkpointing and autoloading with the built-in `\"pickle\"` storage back end.\n",
"\n",
"We can also save and load using an explicit storage interface instance. This allows us to save and load at non-standard locations:"
]
Expand Down
Loading
Loading