xamyzhao / brainstorm

Implementation of "Data augmentation using learned transforms for one-shot medical image segmentation"
MIT License
392 stars 91 forks source link

UnboundLocalError: local variable 'batch_count' referenced before assignment #38

Closed titoriya007 closed 1 year ago

titoriya007 commented 1 year ago

[2023-04-14 22:46:13] TransformModel_mri_source-atlas_0l_100ul_flow_fwd_grad_l2-regfwt1_cc_vm-win9-wt1 training epoch 0/501 Traceback (most recent call last): File "main.py", line 343, in test_every_n_epochs=test_every_n_epochs) File "C:\Users\Administrator\Downloads\brainstorm-master\brainstorm-master\src\experiment_engine.py", line 131, in run_experiment run_args=run_args, File "C:\Users\Administrator\Downloads\brainstorm-master\brainstorm-master\src\experiment_engine.py", line 213, in train_batch_by_batch if batch_count >= 10: UnboundLocalError: local variable 'batch_count' referenced before assignment

Code is working properly for size 256,256,46. When i changed the files with size 256,256,19 then the above error is coming. any idea?