Giter Club home page Giter Club logo

Comments (16)

geggo avatar geggo commented on May 29, 2024

thanks for reporting this bug, fixed.
Gregor

from gpyfft.

yves-surrel avatar yves-surrel commented on May 29, 2024

from gpyfft.

geggo avatar geggo commented on May 29, 2024

Hi Yves,

agreed, building your Python packages yourself can be painful. I use mostly macOS for developing, building there is easy ('python setup.py install' after adjusting the path to clFFT in setup.py), once you have manage to compile clFFT (not so difficult after installing the dependencies with homebrew).

Compiling on Windows is more of a hassle, for Python 2.7 on 64bit Windows I could provide binaries (perhaps on Wednesday), I will add it to the GitHub releases section

Concerning the build directory, the source zip file from GitHub should not contain it (but did not check), it gets created if you (try to) build gpyfft, all files needed for installing are copied into this folder, but there is no automatic cleaning up. So likely it contains useless stuff.

Gregor

from gpyfft.

yves-surrel avatar yves-surrel commented on May 29, 2024

from gpyfft.

yves-surrel avatar yves-surrel commented on May 29, 2024

from gpyfft.

geggo avatar geggo commented on May 29, 2024

Yes, actually your are missing gpyfftlib.pyd (on Windows) or gpyfftlib.so (macOS, Linux), which is the binary Python extension module that provides access to the clFFT library.

Concerning your remark why a compilation is needed: it would be possible to directly call into the library, e.g. using the ctypes or cffi packages, but especially outside Windows this can be unreliable and might lead to crashes. "C libraries are typically meant to be used with a C compiler."

Gregor

from gpyfft.

yves-surrel avatar yves-surrel commented on May 29, 2024

from gpyfft.

geggo avatar geggo commented on May 29, 2024

Hi Yves,
thanks for the hint for compiling on Windows, are you using the Visual Studio compiler? I am using the mingwpy compiler package, which seems not to require an import library. So setup.py needs to be reworked to support compiling on Windows with both msvc and mingw, I'll give it a try tomorrow.

Gregor

from gpyfft.

yves-surrel avatar yves-surrel commented on May 29, 2024

from gpyfft.

yves-surrel avatar yves-surrel commented on May 29, 2024

from gpyfft.

geggo avatar geggo commented on May 29, 2024

Well, have no records for the installation steps, but here an attempt on how to build the clFFT libs on macOS, without guarantee for success

  • install Xcode Command Line Tools

  • install homebrew (http://brew.sh)

  • install cmake:

brew install cmake

  • install boost:

brew install boost

  • get sources for clFFT

  • build clFFT: in src directory of clFFT

cmake -G "Unix Makefiles"
make
optionally:
make install

could be that some other dependencies are missing. In case, try to install them with brew.

hope that helps
Gregor

from gpyfft.

yves-surrel avatar yves-surrel commented on May 29, 2024

from gpyfft.

yves-surrel avatar yves-surrel commented on May 29, 2024

from gpyfft.

geggo avatar geggo commented on May 29, 2024

Hi,
great, you managed to build everything yourself!
The error your encountered typically occurs if you select the CPU device for OpenCL context creation, on macOS it has limited capabilities. Try selecting a GPU device.
Issues are for reporting any problem you find.
best
Gregor

from gpyfft.

yves-surrel avatar yves-surrel commented on May 29, 2024

from gpyfft.

geggo avatar geggo commented on May 29, 2024

This puzzled me a bit, found the issue and added a comment in README.md. Probably you stumbled on a newer feature of pyopencl that create_some_context() silently chooses a device (typically the CPU device) when not run directly in a terminal.

have fun
Gregor

from gpyfft.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.