Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

error messages: allow_pickle=False #8

Open
r-mustafa opened this issue Dec 6, 2019 · 1 comment
Open

error messages: allow_pickle=False #8

r-mustafa opened this issue Dec 6, 2019 · 1 comment

Comments

@r-mustafa
Copy link

r-mustafa commented Dec 6, 2019

Hi,
I got this new error message below, which was never happened before. This error appears both when running regression mode and combining npy files into results.csv.

/etc/profile.d/passwd_expiry.sh: line 20: [: -31: unary operator expected
/etc/profile.d/passwd_expiry.sh: line 27: [: 34: unary operator expected
Traceback (most recent call last):
File "/home/rmustafa/hase//hase.py", line 250, in
mapper.load(args.mapper)
File "/home/rmustafa/hase/hdgwas/tools.py", line 513, in load
self.keys=np.load(os.path.join(keys[0]) )#TODO (middle) not safety to load only one file
File "/home/rmustafa/.local/lib/python2.7/site-packages/numpy/lib/npyio.py", line 447, in load
pickle_kwargs=pickle_kwargs)
File "/home/rmustafa/.local/lib/python2.7/site-packages/numpy/lib/format.py", line 696, in read_array
raise ValueError("Object arrays cannot be loaded when "
ValueError: Object arrays cannot be loaded when allow_pickle=False

I think this is due to recent changes in the numpy library which now requires allow_pickle=True to be explicitly written when loading the objects, so adding allow_pickle=True solves the problem, and this corresponds to the hdgwas/tools.py, hdgwas/data.py (and let me know if I miss anything!).
Thank you.

@CAWarmerdam
Copy link

Hi,
I have also gotten this error message. Since Numpy version 1.16.3 the allow_pickle is set to False by default. Adding the allow_pickle=True in places will indeed solve this issue. For now I am using Numpy version 1.16.2 to circumvent the problem.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants