Closed wangjiawen2013 closed 6 months ago
Hi @wangjiawen2013,
Could you try installing the latest versions of omnipath
and pypath
and try again?
pip install omnipath==1.0.8
pip install pypath-omnipath==0.16.10
Let me know how it goes.
Hi, I installed decouple/omnipath/pypath-omnipath four days ago, so they'are already the latest version.
Hi @deeenes, could you take a look? I think it is related to connection issues
Looks like an incomplete transmission, easiest is to delete the corrupt cache file. To do this, open the log from the session where the error occurred (or run the whole thing again, and open the log when you see the error):
import pypath
import decoupler as dc
test = dc.translate_net(markers, target_organism='rat', unique_by = ('cell_type', 'genesymbol'))
# error happens
pypath.log()
See the bottom of the log for the last accessed cache file and delete it. You'll see something like this:
430892 [2024-02-05 16:51:28] [curl] Creating Curl object to retrieve data from `https://omabrowser.org/api/pairs/9606/10090/?page=21&per_page=1000`
430893 [2024-02-05 16:51:28] [curl] Cache file path: `/home/denes/.cache/pypath/46b04a786b141726f4b3fd9c00276f29-`
430894 [2024-02-05 16:51:28] [curl] Setting up and calling pycurl.
430895 [2024-02-05 16:51:34] [curl] Opening file `/home/denes/.cache/pypath/46b04a786b141726f4b3fd9c00276f29-`
430896 [2024-02-05 16:51:34] [curl] Extracting data from file type `plain`
430897 [2024-02-05 16:51:34] [curl] Opening plain text file `/home/denes/.cache/pypath/46b04a786b141726f4b3fd9c00276f29-`.
430898 [2024-02-05 16:51:34] [curl] Contents of `/home/denes/.cache/pypath/46b04a786b141726f4b3fd9c00276f29-` has been read and the file has been closed.
In the example above, the /home/denes/.cache/pypath/46b04a786b141726f4b3fd9c00276f29-
file has to be deleted. Search for the last one, which caused the error. Finally, try to run translate_net
again.
Thanks, this solved my problem successfully
Hi, I want to translate human gene symbols to rat while the following error ocurred: