Issam28 / Brain-tumor-segmentation

A deep learning based approach for brain tumor MRI segmentation.
190 stars 63 forks source link

ValueError: bad axis2 argument to swapaxes #2

Open sara-kassani opened 6 years ago

sara-kassani commented 6 years ago

In line 74 (gt_im = np.swapaxes(self.train_im, 0, 1)[4]) at extract_patches.py I will get the following error. ValueError: bad axis2 argument to swapaxes.

Issam28 commented 6 years ago

Are you using Brats2017 datasets ? which numpy version do you use?

sara-kassani commented 6 years ago

I'm using brats 2017 and my numpy version is 1.14.2.

Issam28 commented 6 years ago

it's really weird in my local machine i can't reproduce the error can you give more details ?

ritwik12 commented 6 years ago

I am also getting the same error

sara-kassani commented 6 years ago

I've run the code on google colab and the problem was solved. I guess the error caused because of memory error.

Issam28 commented 6 years ago

yes it's probably because of memory when you transform large numpy arrays into np.float you'll quickly run out of memory , i've done this project on a machine that has 64 GO of RAM and i've tested it on google colab which has 13GO of ram and it worked

ritwik12 commented 6 years ago

@sara-kassani I have never used colab. Can you guide me how to use this project for colab? if it's not a long procedure for you to explain.

sara-kassani commented 6 years ago

@ritwik12 It's not easy to work with google colab. I've also worked with http://floydhub.com/ and http://paperspace.com/. I recommend you paperspace.

ritwik12 commented 6 years ago

@sara-kassani ohk, thanks a lot for your help.

agungfathur commented 6 years ago

i try the program, but still error in line 74 with same error. i already try it on google colabs. any solutions?

Issam28 commented 6 years ago

@agungfathur check the filepath of the dataset

TigabuYaya commented 5 years ago

Please could you provide me the output?

TigabuYaya commented 5 years ago

In line 74 (gt_im = np.swapaxes(self.train_im, 0, 1)[4]) at extract_patches.py I will get the following error. ValueError: bad axis2 argument to swapaxes.

This is because your file paths, @ line 216 and 217 ( path_HGG = glob('Brats2017/Brats17TrainingData/HGG/') path_LGG = glob('Brats2017/Brats17TrainingData/LGG/')), are not correctly specified.

takrouni commented 5 years ago

Good morning, Please, i need urgently the Brats2017 dataset Thank you.

TigabuYaya commented 5 years ago

Good morning, Please, i need urgently the Brats2017 dataset Thank you.

your email, please.

takrouni commented 5 years ago

Hello, Same problem :(

Le mer. 5 déc. 2018 à 7:02 PM, Mickind notifications@github.com a écrit :

Hello everyone, How can I find the Brats2017 dataset? I think, without it, I can not execute extract_patches.py. @TigabuYaya https://github.com/TigabuYaya Could you please kindly pass me by email? My e-mail: crtmiky@gmail.com

— You are receiving this because you commented. Reply to this email directly, view it on GitHub https://github.com/Issam28/Brain-tumor-segmentation/issues/2#issuecomment-444582992, or mute the thread https://github.com/notifications/unsubscribe-auth/AO_bWOBzR42xpVzVNXoUJRS2efQhn8L6ks5u2ApQgaJpZM4TJHBb .

Issam28 commented 5 years ago

for everyone's asking for BraTS 2017 or BraTS 2018 datasets you can request them via this website : https://ipp.cbica.upenn.edu/

Wonkun-Chen commented 4 years ago

Hello, is there anybody could send me a BraTS2017 datasets please? when I wrote an email to cbica ask for the datasets, they say they dont provide this datasets, only the latest one, so im here search for it. who can send it to my email(15689432890@163.com)? please!!!

TigabuYaya commented 4 years ago

I hv z dataset

On Sun, Apr 12, 2020, 15:13 Jukern-Steven notifications@github.com wrote:

Hello, is there anybody could send me a BraTS2017 datasets please? when I wrote an email to cbica ask for the datasets, they say they dont provide this datasets, only the latest one, so im here search for it. who can send it to my email(15689432890@163.com)? please!!!

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/Issam28/Brain-tumor-segmentation/issues/2#issuecomment-612605119, or unsubscribe https://github.com/notifications/unsubscribe-auth/AHX2H6CON4O3YPOQHSVP7CDRMGV5NANCNFSM4EZEOBNQ .

cqlouis commented 3 years ago

In line 74 (gt_im = np.swapaxes(self.train_im, 0, 1)[4]) at extract_patches.py I will get the following error. ValueError: bad axis2 argument to swapaxes.

This is because your file paths, @ line 216 and 217 ( path_HGG = glob('Brats2017/Brats17TrainingData/HGG/') path_LGG = glob('Brats2017/Brats17TrainingData/LGG/')), are not correctly specified.

yes! I met the same problem, after I changed the path to absolute path , it worked!