ANTsX / ANTsPyNet

Pre-trained models and utilities for deep learning on medical images in Python
https://antspynet.readthedocs.io
Apache License 2.0
200 stars 29 forks source link

Error: URL fetch failure 403 -- Forbidden, when running antspynet.utilities.brain_extraction #126

Open Lucifer201210 opened 2 months ago

Lucifer201210 commented 2 months ago

When I running the following command line to exact brain from T1.nii.gz, an error happened.

from antspynet.utilities import brain_extraction prob_brain_mask = brain_extraction(raw_img_ants, modality='t1',verbose=True)

the error information was as follows: Brain extraction: retrieving model weights. Brain extraction: retrieving template. Downloading data from https://ndownloader.figshare.com/files/22597175 ...... Exception: URL fetch failure on https://ndownloader.figshare.com/files/22597175: 403 -- Forbidden

It seem to be that the URL(https://ndownloader.figshare.com/files/22597175) was invalid, the command brain_extraction need to download data from the URL. Then I copy the to chrome browser, the URL was forbidden.

Was there any solution to this error?

Lucifer201210 commented 2 months ago

The command line to exact brain from T1.nii.gz was:

`from antspynet.utilities import brain_extraction

brain_extraction prob_brain_mask = brain_extraction(raw_img_ants, modality='t1',verbose=True) `

ntustison commented 2 months ago

Thanks for posting the exact link that is problematic for you. The URL isn't invalid as I don't have any problem downloading that file using chrome. Do you have an institutional block of some sort preventing you from downloading from the figshare site?

cookpa commented 2 months ago

Where are you connecting from? If you are using an online notebook or other shared service, it is possible that figshare is limiting downloads