|
| 1 | +experiment_name: rsunet_snemi_lee2017_modern_sdt |
| 2 | +description: SNEMI3D neuron affinity + SDT learning (9-channel affinity + 1-channel SDT) |
| 3 | + |
| 4 | +_base_: |
| 5 | + - bases/all_profiles.yaml |
| 6 | + |
| 7 | +default: |
| 8 | + system: |
| 9 | + profile: all-gpu-cpu |
| 10 | + model: |
| 11 | + arch: |
| 12 | + profile: rsunet |
| 13 | + input_size: [16, 224, 224] |
| 14 | + output_size: [16, 224, 224] |
| 15 | + out_channels: 10 |
| 16 | + loss: |
| 17 | + profile: loss_bd |
| 18 | + data: |
| 19 | + label_transform: |
| 20 | + profile: label_affinity_9_sdt |
| 21 | + resolution: [30, 6, 6] |
| 22 | + dataloader: |
| 23 | + profile: cached |
| 24 | + patch_size: [16, 224, 224] |
| 25 | + data_transform: |
| 26 | + # Keep symmetric full-volume context padding on the inference input. |
| 27 | + pad_size: [17, 128, 128] |
| 28 | + augmentation: |
| 29 | + profile: aug_em_neuron |
| 30 | + inference: |
| 31 | + sliding_window: |
| 32 | + window_size: [16, 224, 224] |
| 33 | + sw_batch_size: 1 |
| 34 | + keep_input_on_cpu: false |
| 35 | + test_time_augmentation: |
| 36 | + enabled: false |
| 37 | + #enabled: true |
| 38 | + patch_first_local: true |
| 39 | + flip_axes: all |
| 40 | + rotation90_axes: [[1, 2]] |
| 41 | + activation_profile: act_bd |
| 42 | + #select_channel: [0, 1, 2, 9] |
| 43 | + ensemble_mode: [["0:9", min], ["9:", mean]] |
| 44 | + postprocessing: |
| 45 | + enabled: true |
| 46 | + # crop_pad + affinity_crop[(17,0),(17,0),(17,0)] = pad_size [17,128,128]: |
| 47 | + # Z: 0+17=17, 17+0=17 | Y/X: 111+17=128, 128+0=128 |
| 48 | + crop_pad: [0, 17, 111, 128, 111, 128] |
| 49 | + save_prediction: |
| 50 | + enabled: true |
| 51 | + decoding_profile: decoding_waterz |
| 52 | + evaluation: |
| 53 | + enabled: true |
| 54 | + metrics: [adapted_rand] |
| 55 | + |
| 56 | + |
| 57 | +train: |
| 58 | + data: |
| 59 | + train: |
| 60 | + image: datasets/SNEMI/train-input.tif |
| 61 | + label: datasets/SNEMI/train-labels.tif |
| 62 | + |
| 63 | + optimization: |
| 64 | + profile: warmup_cosine_lr |
| 65 | + max_epochs: 200 |
| 66 | + n_steps_per_epoch: 1000 |
| 67 | + monitor: |
| 68 | + logging: |
| 69 | + scalar: |
| 70 | + loss: [train_loss_total_epoch, train_loss_affinity_total, train_loss_sdt_total] |
| 71 | + loss_every_n_steps: 50 |
| 72 | + images: |
| 73 | + log_every_n_epochs: 10 |
| 74 | + max_images: 8 |
| 75 | + num_slices: 2 |
| 76 | + channel_mode: all |
| 77 | + checkpoint: |
| 78 | + save_top_k: 3 |
| 79 | + monitor: train_loss_total_epoch |
| 80 | + mode: min |
| 81 | + |
| 82 | +test: |
| 83 | + data: |
| 84 | + test: |
| 85 | + path: datasets/SNEMI/ |
| 86 | + # image: [train-input.tif, test-input_z29.h5] |
| 87 | + # label: [train-labels.tif, test-labels.h5] |
| 88 | + #image: train-input.tif |
| 89 | + #label: train-labels.tif |
| 90 | + #image: test-input_z29.h5 |
| 91 | + image: test-input.tif |
| 92 | + label: test-labels.h5 |
| 93 | + resolution: [30, 6, 6] |
| 94 | + inference: |
| 95 | + decoding: |
| 96 | + - profile: decoding_waterz |
| 97 | + kwargs: |
| 98 | + thresholds: 0.4 |
| 99 | + merge_function: aff85_his256 |
| 100 | + aff_threshold: [0.001, 0.999] |
| 101 | + |
| 102 | +# ============================================================================ |
| 103 | +# Parameter tuning for waterz agglomeration thresholds (--mode tune) |
| 104 | +# ============================================================================ |
| 105 | +tune: |
| 106 | + profile: tune_waterz |
| 107 | + n_trials: 25 |
| 108 | + study_name: snemi_waterz_tuning |
| 109 | + data: |
| 110 | + val: |
| 111 | + image: datasets/SNEMI/test-input.tif |
| 112 | + label: datasets/SNEMI/test-labels.h5 |
| 113 | + #image: datasets/SNEMI/train-input.tif |
| 114 | + #label: datasets/SNEMI/train-labels.tif |
| 115 | + # Override profile defaults for SNEMI-specific search ranges |
| 116 | + parameter_space: |
| 117 | + decoding: |
| 118 | + defaults: |
| 119 | + thresholds: 0.4 |
| 120 | + merge_function: aff85_his256 |
| 121 | + aff_threshold: [0.001, 0.999] |
| 122 | + parameters: |
| 123 | + merge_function: |
| 124 | + type: categorical |
| 125 | + choices: [aff85_his256, aff75_his256, aff50_his256] |
| 126 | + description: "Agglomeration scoring function (quantile via histogram)" |
| 127 | + thresholds: |
| 128 | + range: [0.1, 0.9] |
| 129 | + step: 0.05 |
| 130 | + aff_threshold_low: |
| 131 | + range: [0.001, 0.3] |
| 132 | + step: 0.01 |
| 133 | + param_group: aff_threshold |
| 134 | + tuple_index: 0 |
| 135 | + aff_threshold_high: |
| 136 | + range: [0.8, 0.9999] |
| 137 | + step: 0.01 |
| 138 | + param_group: aff_threshold |
| 139 | + tuple_index: 1 |
0 commit comments