I'm trying to read gctx files with cmapPy. This is my code:
from cmapPy.pandasGEXpress.parse_gct import parse
from cmapPy.pandasGEXpress.write_gct import write
parse("C:/Users/User/Desktop/gctx/CAS9_BASELINE_LEVEL3_BING__n10721x10174.gctx")
This is the error:
(base) C:\Users\User\Desktop\hello>D:/anaconda/python.exe c:/Users/User/Desktop/gctx/readgcxtx.py
Traceback (most recent call last):
File "c:/Users/User/Desktop/gctx/readgcxtx.py", line 3, in <module>
parse("C:/Users/User/Desktop/gctx/CAS9_BASELINE_LEVEL3_BING__n10721x10174.gctx")
File "D:\anaconda\lib\site-packages\cmapPy\pandasGEXpress\parse_gct.py", line 136, in parse
num_row_metadata, num_col_metadata) = read_version_and_dims(file_path)
File "D:\anaconda\lib\site-packages\cmapPy\pandasGEXpress\parse_gct.py", line 168, in read_version_and_dims
version = f.readline().strip().lstrip("#")
File "D:\anaconda\lib\encodings\cp1252.py", line 23, in decode
return codecs.charmap_decode(input,self.errors,decoding_table)[0]
UnicodeDecodeError: 'charmap' codec can't decode byte 0x90 in position 2440: character maps to <undefined>
I tried changing the path with double slashes or r"..." but it doesn't work. Thanks.