Giter VIP home page Giter VIP logo

Comments (7)

Peter554 avatar Peter554 commented on September 18, 2024 1

Thanks @fortunechen. Yes I also used to use the conda distribution of spams. More recently spams was made available on PyPI so I wanted to switch to that to make install simpler (not everyone uses conda). However it seems to be too buggy at the moment so I will consider to revert to conda again.

from staintools.

msschwartz21 avatar msschwartz21 commented on September 18, 2024

After commenting out the following lines,

# with open('README.md') as f:
#     readme = f.read()

setup(
    name='staintools',
    version='2.1.1',
    description='A package for tissue image stain normalization, augmentation and more.',
#     long_description=readme,
    author='Peter Byfield',
    author_email='[email protected]',
    url='https://github.com/Peter554/StainTools',
    packages=find_packages(exclude=('tests')),
    install_requires=[
        'numpy',
        'opencv-python',
        'spams',
        'matplotlib'
    ]
)

I tried installing from a local cloned directory using pip install -e . and triggered the following error:

Command "/usr/bin/python3 -u -c "import setuptools, tokenize;__file__='/tmp/pip-install-ffbvu0zn/spams/setup.py';f=getattr(tokenize, 'open', open)(__file__);code=f.read().replace('\r\n', '\n');f.close();exec(compile(code, __file__, 'exec'))" install --record /tmp/pip-record-3qf2_y4e/install-record.txt --single-version-externally-managed --compile" failed with error code 1 in /tmp/pip-install-ffbvu0zn/spams/

from staintools.

Peter554 avatar Peter554 commented on September 18, 2024

I haven't seen the first error before regarding readme encoding, just it should be easily fixable.

I'm more concerned about the second one regarding SPAMS. This is a package dependency that gives rather a headache it seems. It was recently made available of PyPI but unfortunately the install pip install spams seems very buggy. Ideally that would be fixed or we would get rid of this dependency some how (but so far I haven't found anything suitable - sklearn did seem to have something similar but it was much slower).

from staintools.

Peter554 avatar Peter554 commented on September 18, 2024

I've sent the SPAMS dev team an email to ask about their pip install.

from staintools.

fortunechen avatar fortunechen commented on September 18, 2024

After commenting out the following lines,

# with open('README.md') as f:
#     readme = f.read()

setup(
    name='staintools',
    version='2.1.1',
    description='A package for tissue image stain normalization, augmentation and more.',
#     long_description=readme,
    author='Peter Byfield',
    author_email='[email protected]',
    url='https://github.com/Peter554/StainTools',
    packages=find_packages(exclude=('tests')),
    install_requires=[
        'numpy',
        'opencv-python',
        'spams',
        'matplotlib'
    ]
)

I tried installing from a local cloned directory using pip install -e . and triggered the following error:

Command "/usr/bin/python3 -u -c "import setuptools, tokenize;__file__='/tmp/pip-install-ffbvu0zn/spams/setup.py';f=getattr(tokenize, 'open', open)(__file__);code=f.read().replace('\r\n', '\n');f.close();exec(compile(code, __file__, 'exec'))" install --record /tmp/pip-record-3qf2_y4e/install-record.txt --single-version-externally-managed --compile" failed with error code 1 in /tmp/pip-install-ffbvu0zn/spams/

I installed spams first by using conda https://anaconda.org/conda-forge/python-spams, and commented install_requires lines, then pip install -e . worked.

from staintools.

Peter554 avatar Peter554 commented on September 18, 2024

Response from SPAMS says they are looking into it but don't expect anything too soon. So for now I'll keep this issue open and have updated the README to advise using conda if possible.

pip install is currently broken due to the dependency on SPAMS. This issue has been raised with the SPAMS developers. In the meantime if you use conda you may have better luck resolving the SPAMS dependency via conda-forge:

https://anaconda.org/conda-forge/python-spams

from staintools.

Peter554 avatar Peter554 commented on September 18, 2024

Update:

  • long_description=readme issue should now be resolved.
  • SPAMS install. For now have removed from setup.py and updated README to guide users to the conda option.

from staintools.

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.