Closed neurolabusc closed 4 years ago
Hi there, we officially support Ubuntu as this is the only operating system we can test the code on. It seems like the downloading of the network weights failed on your system, but the error message you posted looks incomplete. The bottom-most part is missing and that usually tells us what the actual problem is. Could you please post the entire error message so that I can try to figure out what is going on? Please note that running on CPU is slow and requires A LOT of RAM. From your CPU (i5-8259U) my guess is that your system has 8 or 16GB which may not be enough. The amount of RAM needed to run HD-Bet on CPU is beyond our control because this seems to be an intrinsic problem to pytorch. Best, Fabian
>hd-bet -i 2_T1.nii.gz -device cpu -mode fast -tta 0
########################
If you are using hd-bet, please cite the following paper:
Isensee F, Schell M, Tursunova I, Brugnara G, Bonekamp D, Neuberger U, Wick A, Schlemmer HP, Heiland S, Wick W,Bendszus M, Maier-Hein KH, Kickingereder P. Automated brain extraction of multi-sequence MRI using artificialneural networks. arXiv preprint arXiv:1901.11341, 2019.
########################
Downloading https://zenodo.org/record/2540695/files/0.model?download=1 ...
Traceback (most recent call last):
File "/Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/urllib/request.py", line 1317, in do_open
encode_chunked=req.has_header('Transfer-encoding'))
File "/Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/http/client.py", line 1244, in request
self._send_request(method, url, body, headers, encode_chunked)
File "/Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/http/client.py", line 1290, in _send_request
self.endheaders(body, encode_chunked=encode_chunked)
File "/Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/http/client.py", line 1239, in endheaders
self._send_output(message_body, encode_chunked=encode_chunked)
File "/Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/http/client.py", line 1026, in _send_output
self.send(msg)
File "/Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/http/client.py", line 966, in send
self.connect()
File "/Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/http/client.py", line 1414, in connect
server_hostname=server_hostname)
File "/Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/ssl.py", line 423, in wrap_socket
session=session
File "/Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/ssl.py", line 870, in _create
self.do_handshake()
File "/Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/ssl.py", line 1139, in do_handshake
self._sslobj.do_handshake()
ssl.SSLCertVerificationError: [SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed: unable to get local issuer certificate (_ssl.c:1076)
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/Library/Frameworks/Python.framework/Versions/3.7/bin/hd-bet", line 7, in <module>
exec(compile(f.read(), __file__, 'exec'))
File "/Users/chris/Downloads/HD-BET/HD_BET/hd-bet", line 119, in <module>
run_hd_bet(input_files, output_files, mode, config_file, device, pp, tta, save_mask, overwrite_existing)
File "/Users/chris/Downloads/HD-BET/HD_BET/run.py", line 42, in run_hd_bet
maybe_download_parameters(0)
File "/Users/chris/Downloads/HD-BET/HD_BET/utils.py", line 35, in maybe_download_parameters
data = urlopen(url).read()
File "/Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/urllib/request.py", line 222, in urlopen
return opener.open(url, data, timeout)
File "/Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/urllib/request.py", line 525, in open
response = self._open(req, data)
File "/Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/urllib/request.py", line 543, in _open
'_open', req)
File "/Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/urllib/request.py", line 503, in _call_chain
result = func(*args)
File "/Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/urllib/request.py", line 1360, in https_open
context=self._context, check_hostname=self._check_hostname)
File "/Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/urllib/request.py", line 1319, in do_open
raise URLError(err)
urllib.error.URLError: <urlopen error [SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed: unable to get local issuer certificate (_ssl.c:1076)>
Yes, that does fix the issue. Thanks! The results do look very nice.
I did get one deprecation warning that you may want to address:
/Users/chris/Downloads/HD-BET/HD_BET/utils.py:74: UserWarning: The argument 'neighbors' is deprecated and will be removed in scikit-image 0.18, use 'connectivity' instead. For neighbors=8, use connectivity=3
lbls = label(mask, 8)
Hi, glad to hear it now works and that the results look good. If you run into any other issues please let me know. I will look into the deprecation warning. Best, Fabian
Hi, glad to hear it now works and that the results look good. If you run into any other issues please let me know. I will look into the deprecation warning. Best, Fabian
label(mask, connectivity=3) worked for me
Hello What operating systems does this support. I tried to run this on my MacOS computer with a simple 1mm isotropic T1-image and get the following errors (running as sudo did not help):