Skip to content

Commit 2ac9b9d

Browse files
authored
Merge pull request #206 from Exabyte-io/feature/SOF-7327
feature/SOF 7327
2 parents 5b07e2d + 9b17237 commit 2ac9b9d

19 files changed

+41
-1799
lines changed

examples/job/create_and_submit_job.ipynb

+3-2
Original file line numberDiff line numberDiff line change
@@ -181,8 +181,9 @@
181181
},
182182
"outputs": [],
183183
"source": [
184-
"default_material = material_endpoints.list({\"isDefault\": True, \"owner._id\": ACCOUNT_ID})[0]\n",
185-
"default_workflow = workflow_endpoints.list({\"isDefault\": True, \"owner._id\": ACCOUNT_ID})[0]\n",
184+
"OWNER_ID = os.getenv(\"ORGANIZATION_ID\") or ACCOUNT_ID\n",
185+
"default_material = material_endpoints.list({\"isDefault\": True, \"owner._id\": OWNER_ID})[0]\n",
186+
"default_workflow = workflow_endpoints.list({\"isDefault\": True, \"owner._id\": OWNER_ID})[0]\n",
186187
"\n",
187188
"material_id = default_material[\"_id\"]\n",
188189
"workflow_id = default_workflow[\"_id\"]\n",

examples/job/create_and_submit_job.py

-127
This file was deleted.

examples/job/get-file-from-job.ipynb

+2-1
Original file line numberDiff line numberDiff line change
@@ -192,7 +192,8 @@
192192
"source": [
193193
"# Get some account information\n",
194194
"project_endpoints = ProjectEndpoints(*ENDPOINT_ARGS)\n",
195-
"project_metadata = project_endpoints.list({\"isDefault\": True, \"owner._id\": ACCOUNT_ID})[0]\n",
195+
"OWNER_ID = os.getenv(\"ORGANIZATION_ID\") or ACCOUNT_ID\n",
196+
"project_metadata = project_endpoints.list({\"isDefault\": True, \"owner._id\": OWNER_ID})[0]\n",
196197
"project_id = project_metadata[\"_id\"]\n",
197198
"owner_id = project_metadata[\"owner\"][\"_id\"]\n",
198199
"\n",

examples/job/get-file-from-job.py

-227
This file was deleted.

examples/job/ml-train-model-predict-properties.ipynb

+4-3
Original file line numberDiff line numberDiff line change
@@ -295,8 +295,9 @@
295295
},
296296
"outputs": [],
297297
"source": [
298-
"owner_id = material_endpoints.list({\"isDefault\": True, \"owner._id\": ACCOUNT_ID})[0][\"owner\"][\"_id\"]\n",
299-
"project_id = project_endpoints.list({\"isDefault\": True, \"owner._id\": ACCOUNT_ID})[0][\"_id\"]"
298+
"OWNER_ID = os.getenv(\"ORGANIZATION_ID\") or ACCOUNT_ID\n",
299+
"owner_id = material_endpoints.list({\"isDefault\": True, \"owner._id\": OWNER_ID})[0][\"owner\"][\"_id\"]\n",
300+
"project_id = project_endpoints.list({\"isDefault\": True, \"owner._id\": OWNER_ID})[0][\"_id\"]"
300301
]
301302
},
302303
{
@@ -373,7 +374,7 @@
373374
"source": [
374375
"compute = job_endpoints.get_compute(CLUSTER, PPN, NODES, QUEUE, TIME_LIMIT)\n",
375376
"jobs = job_endpoints.create_by_ids(\n",
376-
" train_materials, band_gap_workflow_id, project_id, owner_id, JOB_NAME_PREFIX, compute\n",
377+
" train_materials, band_gap_workflow_id, project_id, JOB_NAME_PREFIX, owner_id, compute\n",
377378
")"
378379
]
379380
},

0 commit comments

Comments
 (0)