Code Monkey home page Code Monkey logo

Comments (7)

dkazanc avatar dkazanc commented on September 27, 2024

UPD: It is not related to the Compiled code actually.

I'm seeing the same problem consistently across other packages where distutils being used. I can only assume that the build is broken, possibly due to deprecation of distutils which comes from setuptools. And since we're using significantly newer setuptools in our environment than the recommended version (<60), this might be because of that.

Worth thinking upgrading to skbuild, for instance?

from ccpi-regularisation-toolkit.

paskino avatar paskino commented on September 27, 2024

I found the same error somewhere else SyneRBI/SIRF-SuperBuild#832

from ccpi-regularisation-toolkit.

paskino avatar paskino commented on September 27, 2024

Probably it's better to start by changing this line

https://github.com/vais-ral/CCPi-Regularisation-Toolkit/blob/a3dc5201a75705c1a8e6f840f85d7d811023ba71/src/Python/CMakeLists.txt#L109

into using pip install . like here

from ccpi-regularisation-toolkit.

paskino avatar paskino commented on September 27, 2024

On CI the current build process has the warning:

        ********************************************************************************
        Please avoid running ``setup.py`` directly.
        Instead, use pypa/build, pypa/installer or other
        standards-based tools.

        See https://blog.ganssle.io/articles/2021/10/setup-py-deprecated.html for details.
        ********************************************************************************

from ccpi-regularisation-toolkit.

casperdcl avatar casperdcl commented on September 27, 2024

Worth thinking upgrading to skbuild, for instance?

or the successor scikit-build-core now :) - would also fix #114 -> #115

from ccpi-regularisation-toolkit.

dkazanc avatar dkazanc commented on September 27, 2024

I'm currently refactoring TomoPhantom into Ctypes only package. Cmake still triggers the build of the C code into shared library but it is a totally independent entity from the Python code of the package, which can be simply pip installed. This is how TomoPy group does the build as well. They've got libtomo library for C/Cuda-C code and then just Python stuff. This is very convenient when you're working as a developer as you don't need to rebuild the package all the time when you're concerned only with the Python code. I guess the down side is that you need two conda recipes, but that can be done easily (Tomopy uses conda-forge feedstock for that).

For Regularisation Toolkit, as there is not much of Python, may be Cython build would work OK, but yes skbuild could be also an option. I've done a mini version of the toolkit slightly differently with Cython bindings and it seems to avoid the errors here. I can share it bellow. This is a pure play so far, but I guess we can potentially re-factor it in a similar way?
sofia.zip

from ccpi-regularisation-toolkit.

casperdcl avatar casperdcl commented on September 27, 2024

https://docs.cython.org/en/latest/src/userguide/source_files_and_compilation.html#configuring-the-c-build looks like we need to replace Cython.Distutils.build_ext with Cython.Build.cythonize

from ccpi-regularisation-toolkit.

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.