|
160 | 160 | "from brainles_preprocessing.modality import Modality, CenterModality\n", |
161 | 161 | "from brainles_preprocessing.preprocessor import Preprocessor\n", |
162 | 162 | "from brainles_preprocessing.registration import ANTsRegistrator\n", |
163 | | - "from brainles_preprocessing.normalization.percentile_normalizer import PercentileNormalizer\n", |
| 163 | + "from brainles_preprocessing.normalization.percentile_normalizer import (\n", |
| 164 | + " PercentileNormalizer,\n", |
| 165 | + ")\n", |
164 | 166 | "\n", |
165 | 167 | "import utils" |
166 | 168 | ] |
|
191 | 193 | "t1c_normalized_bet_output_path = output_dir / \"t1c_normalized_bet.nii.gz\"\n", |
192 | 194 | "t1c_normalized_defaced_output_path = output_dir / \"t1c_normalized_defaced.nii.gz\"\n", |
193 | 195 | "t1c_bet_mask = output_dir / \"t1c_bet_mask.nii.gz\"\n", |
194 | | - "t1c_defacing_mask = output_dir / \"t1c_defacing_mask.nii.gz\" \n", |
| 196 | + "t1c_defacing_mask = output_dir / \"t1c_defacing_mask.nii.gz\"\n", |
195 | 197 | "\n", |
196 | 198 | "t1_normalized_bet_output_path = output_dir / \"t1_normalized_bet.nii.gz\"\n", |
197 | 199 | "fla_normalized_bet_output_path = output_dir / \"fla_normalized_bet.nii.gz\"\n", |
|
446 | 448 | ], |
447 | 449 | "source": [ |
448 | 450 | "# inspect the different outputs for the center modality (normalized atlas registered with skull, brain extracted (bet) and defaced)\n", |
449 | | - "utils.visualize_data(files=[t1c_normalized_skull_output_path, t1c_normalized_bet_output_path, t1c_normalized_defaced_output_path], label=\"T1C outputs\")\n", |
| 451 | + "utils.visualize_data(\n", |
| 452 | + " files=[\n", |
| 453 | + " t1c_normalized_skull_output_path,\n", |
| 454 | + " t1c_normalized_bet_output_path,\n", |
| 455 | + " t1c_normalized_defaced_output_path,\n", |
| 456 | + " ],\n", |
| 457 | + " label=\"T1C outputs\",\n", |
| 458 | + ")\n", |
450 | 459 | "\n", |
451 | 460 | "# inspect the different outputs for the all modalities (normalized atlas registered brain extracted (bet))\n", |
452 | | - "utils.visualize_data(files=[t1c_normalized_bet_output_path, t1_normalized_bet_output_path, fla_normalized_bet_output_path, t2_normalized_bet_output_path], label=\"BET outputs\")\n", |
| 461 | + "utils.visualize_data(\n", |
| 462 | + " files=[\n", |
| 463 | + " t1c_normalized_bet_output_path,\n", |
| 464 | + " t1_normalized_bet_output_path,\n", |
| 465 | + " fla_normalized_bet_output_path,\n", |
| 466 | + " t2_normalized_bet_output_path,\n", |
| 467 | + " ],\n", |
| 468 | + " label=\"BET outputs\",\n", |
| 469 | + ")\n", |
453 | 470 | "\n", |
454 | 471 | "# showcase the defacing result from a more suitable angle\n", |
455 | 472 | "utils.visualize_defacing(file=t1c_normalized_defaced_output_path)" |
|
0 commit comments