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

Newer numpy (f2py?) produces strange errors #62

Open
jmlorenzi opened this issue Oct 12, 2017 · 3 comments
Open

Newer numpy (f2py?) produces strange errors #62

jmlorenzi opened this issue Oct 12, 2017 · 3 comments

Comments

@jmlorenzi
Copy link
Contributor

Expected behavior

kmos models should be able to run after being compiled with any of the three backends. In addition running kmos bench should return output similar to

Using the [lat_int] backend.
1000000 steps took 1.23 seconds
Or 8.12e+05 steps/s

Actual behavior

When using numpy 1.13.3, models compile with no apparent errors, however when trying to run a model compiled with otf I get a Segmentation Fault. In addition, when running kmos bench on a model compiled with lat_int, the output looks like

Using the [???] backend.
1000000 steps took 1.24 seconds
Or 8.08e+05 steps/s

Notice the question marks instead of the backend name. This does not happen with the local_smart backend.

Steps to reproduce the issue

  1. Update numpy to ver 1.13.3
  2. Pick your favorite otf-enabled model, recompile it with kmos export -b otf
  3. Run kmos bench on the model folder

2a. Pick your favorite "default backend" kmos model, compile it with kmos export -b lat_int
3b. Run kmos bench on the model folder

System information

kmos version: 0.3.21
Linux Debian Jessie

Downgrading to numpy 1.8.2 solves the issue. Before I investigate this, it would be nice is somebody could try to reproduce this issue, to make sure is not something wrong with my installation.

@mseibt
Copy link

mseibt commented Oct 13, 2017

I was able to reproduce this issue. However both run and bench produce a SegFault for me.

I used numpy 1.11.0 which works fine and numpy 1.13.3 which does not.

@jmlorenzi
Copy link
Contributor Author

Hi Michael,

Thanks a lot for reproducing this. Yes, the SegFault seems to occur as soon as you try to import kmos.run. I will try to take a look into this next week.

@wulx
Copy link

wulx commented Oct 25, 2017

Hi Juan,
SegFault happends when gfortran-7 is used, and it disappears after I update alternatives to gfortran-6.
My OS is the latest Ubuntu 17.10. After hundreds of tries, I found that sudo apt install python-ase works for me while pip install ... makes tons of trouble.

The details are displayed as follows.

mc@mc-server:~/AlOnSi/AlOnSi_otf$ ase info
platform        Linux-4.13.0-16-generic-x86_64-with-Ubuntu-17.10-artful
python-3.6.3    /usr/bin/python3
ase-3.14.1      /usr/lib/python3/dist-packages/ase/
numpy-1.12.1    /usr/lib/python3/dist-packages/numpy/
scipy-0.18.1    /usr/lib/python3/dist-packages/scipy/
mc@mc-server:~/AlOnSi/AlOnSi_otf$ kmos --version
0.3.21
mc@mc-server:~/AlOnSi/AlOnSi_otf$ gfortran --version
GNU Fortran (Ubuntu 6.4.0-8ubuntu1) 6.4.0 20171010
Copyright (C) 2017 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.  There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

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

3 participants