Skip to content

Commit

Permalink
updated process config example
Browse files Browse the repository at this point in the history
  • Loading branch information
AlexPatrie committed Mar 7, 2024
1 parent 32480f8 commit 2f96b69
Showing 1 changed file with 68 additions and 15 deletions.
83 changes: 68 additions & 15 deletions notebooks/playground.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -51,43 +51,96 @@
},
{
"cell_type": "code",
"execution_count": 5,
"id": "598687d66ea4e4bb",
"execution_count": 6,
"id": "68cb05b5c9a5a184",
"metadata": {
"ExecuteTime": {
"end_time": "2024-03-07T18:34:55.924112Z",
"start_time": "2024-03-07T18:34:55.922998Z"
"end_time": "2024-03-07T23:41:52.909903Z",
"start_time": "2024-03-07T23:41:52.906392Z"
},
"collapsed": false
},
"outputs": [],
"source": []
"source": [
"from biosimulator_processes.data_model import dynamic_process_config as DynamicProcessConfig"
]
},
{
"cell_type": "code",
"execution_count": 5,
"id": "7e75da35b0b21814",
"execution_count": 7,
"id": "598687d66ea4e4bb",
"metadata": {
"ExecuteTime": {
"end_time": "2024-03-07T18:34:55.925666Z",
"start_time": "2024-03-07T18:34:55.924640Z"
"end_time": "2024-03-07T23:41:53.518784Z",
"start_time": "2024-03-07T23:41:53.513287Z"
},
"collapsed": false
},
"outputs": [],
"source": []
"outputs": [
{
"data": {
"text/plain": [
"ProcessConfig(a='234', b=20, age=29)"
]
},
"execution_count": 7,
"metadata": {},
"output_type": "execute_result"
}
],
"source": [
"x = {'a': '234', 'b': 20}\n",
"config = DynamicProcessConfig(config=x, age=29)\n",
"\n",
"config"
]
},
{
"cell_type": "code",
"execution_count": 5,
"id": "fa3f17670d0ac36d",
"execution_count": 8,
"id": "3821d2077e715010",
"metadata": {
"ExecuteTime": {
"end_time": "2024-03-07T18:34:55.927270Z",
"start_time": "2024-03-07T18:34:55.926229Z"
"end_time": "2024-03-07T23:42:10.500508Z",
"start_time": "2024-03-07T23:42:10.496137Z"
},
"collapsed": false
},
"outputs": [
{
"data": {
"text/plain": [
"RoseProcessConfig(species='human', origin='USA', age=29, sibilings=1, car='Toyota')"
]
},
"execution_count": 8,
"metadata": {},
"output_type": "execute_result"
}
],
"source": [
"human_config = {\n",
" 'species': 'human',\n",
" 'origin': 'USA'}\n",
"\n",
"rose_config = DynamicProcessConfig(\n",
" name='rose',\n",
" config=human_config,\n",
" age=29,\n",
" sibilings=1,\n",
" car='Toyota')\n",
"\n",
"\n",
"rose_config"
]
},
{
"cell_type": "code",
"execution_count": null,
"id": "cd930a7626b54e0b",
"metadata": {
"collapsed": false
},
"outputs": [],
"source": []
}
Expand Down

0 comments on commit 2f96b69

Please sign in to comment.