Skip to content

Installation errors on MacOS X #157

@apal90

Description

@apal90

I am trying to install pele on my MacOS X (Sierra), and I get the following error. I am copy-pasting everything.

Can someone tell me how to correct this?

$ python setup_with_cmake.py build_ext -i --fcompiler=gfortran
Namespace(compiler=None, j=4) ['setup_with_cmake.py', 'build_ext', '-i', '--fcompiler=gfortran', '-c', 'unix']
fatal: Not a git repository (or any of the parent directories): .git
Cythonizing sources
Processing pele/angleaxis/_cpp_aa.pyx
cython --fast-fail --cplus -I /Users/apal/Downloads/pele-master/pele/potentials -v -o _cpp_aa.cxx _cpp_aa.pyx
Compiling /Users/apal/Downloads/pele-master/pele/angleaxis/_cpp_aa.pyx
warning: /Users/apal/Downloads/pele-master/pele/potentials/_pele.pxd:68:40: Buffer unpacking not optimized away.
warning: /Users/apal/Downloads/pele-master/pele/potentials/_pele.pxd:68:40: Buffer unpacking not optimized away.
warning: /Users/apal/Downloads/pele-master/pele/potentials/_pele.pxd:89:47: Buffer unpacking not optimized away.
warning: /Users/apal/Downloads/pele-master/pele/potentials/_pele.pxd:89:47: Buffer unpacking not optimized away.
warning: /Users/apal/Downloads/pele-master/pele/potentials/_pele.pxd:121:43: Buffer unpacking not optimized away.
warning: /Users/apal/Downloads/pele-master/pele/potentials/_pele.pxd:121:43: Buffer unpacking not optimized away.

Error compiling Cython file:
------------------------------------------------------------
...
cdef inline np.ndarray[double, ndim=1] pele_array_to_np(Array[double] v):
    """copy the data in a pele::Array into a new numpy array
    """
    cdef int i
    cdef int N = v.size()
    cdef np.ndarray[double, ndim=1] vnew = np.zeros(N)
                                            ^
------------------------------------------------------------

/Users/apal/Downloads/pele-master/pele/potentials/_pele.pxd:84:45: cimported module has no attribute 'zeros'
Traceback (most recent call last):
  File "/Users/apal/Downloads/pele-master/cythonize.py", line 200, in <module>
    main()
  File "/Users/apal/Downloads/pele-master/cythonize.py", line 197, in main
    find_process_files(root_dir)
  File "/Users/apal/Downloads/pele-master/cythonize.py", line 184, in find_process_files
    process(cur_dir, fromfile, tofile, function, hash_db)
  File "/Users/apal/Downloads/pele-master/cythonize.py", line 160, in process
    processor_function(fromfile, tofile)
  File "/Users/apal/Downloads/pele-master/cythonize.py", line 78, in process_pyx
    raise Exception('Cython failed')
Exception: Cython failed
Traceback (most recent call last):
  File "setup_with_cmake.py", line 106, in <module>
    generate_cython()
  File "setup_with_cmake.py", line 104, in generate_cython
    raise RuntimeError("Running cythonize failed!")
RuntimeError: Running cythonize failed!

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions