|
245 | 245 | " \"spacing_xy\": 1.5,\n", |
246 | 246 | " \"spacing_z\": 1.5,\n", |
247 | 247 | " \"autoencoder_def#num_splits\": 16,\n", |
248 | | - " \"mask_generation_autoencoder_def#num_splits\": 16\n", |
| 248 | + " \"mask_generation_autoencoder_def#num_splits\": 16,\n", |
249 | 249 | "}\n", |
250 | 250 | "workflow = create_workflow(\n", |
251 | 251 | " config_file=os.path.join(bundle_root, \"configs/inference.json\"),\n", |
252 | 252 | " workflow_type=\"inference\",\n", |
253 | 253 | " bundle_root=bundle_root,\n", |
254 | | - " **override\n", |
| 254 | + " **override,\n", |
255 | 255 | ")\n", |
256 | 256 | "\n", |
257 | 257 | "# uncomment this line to run the inference workflow\n", |
|
459 | 459 | " },\n", |
460 | 460 | "}\n", |
461 | 461 | "\n", |
| 462 | + "\n", |
462 | 463 | "def nii_to_mesh(input_nii_path, output_nii_path, output_obj_path):\n", |
463 | 464 | " \"\"\"\n", |
464 | 465 | " This function converts each organ into a separate OBJ file and generates a GLTF file\n", |
465 | 466 | " containing all organs with hierarchical structure.\n", |
466 | 467 | " It processes the input NIfTI file and groups 140 labels into 17 categories.\n", |
467 | | - " \n", |
| 468 | + "\n", |
468 | 469 | " Args:\n", |
469 | 470 | " input_nii_path: path to the nii file\n", |
470 | 471 | " output_nii_path: path to save the obj files\n", |
|
516 | 517 | " )\n", |
517 | 518 | " print(f\"Saved whole segmentation {all_organ_filename}\")\n", |
518 | 519 | "\n", |
| 520 | + "\n", |
519 | 521 | "input_nii_path = f\"{bundle_root}/datasets/IntegrationTest-AbdomenCT.nii.gz\"\n", |
520 | 522 | "output_nii_path = f\"{bundle_root}/datasets/monai/nii\"\n", |
521 | 523 | "output_obj_path = f\"{bundle_root}/datasets/monai/obj\"\n", |
|
0 commit comments