unable to instal Mahotas python library - python

I am unable to install Mahotas python library on my pc. I try to install it by using the pip installation. But when i try it returns the following error message.
enter image description here

Author of mahotas here. The recommended installation method is to use conda-forge. It should support all major operating systems:
https://anaconda.org/conda-forge/mahotas

Install Visual C++ Build tools from https://visualstudio.microsoft.com/visual-cpp-build-tools/
Restart your machine and then try
pip install mahotas
If you have conda installed, you can install mahotas using the following pair of commands:
conda config --add channels conda-forge
conda install mahotas

Related

how install powerlaw python package

I need to install the powerlaw package in python.
if I call from the prompt, the python list turns out to be installed.
Instead when I open spyder for python it doesn't recognize the package.
how can I do?
Go to your command prompt and try this one;
conda install -c mlgill powerlaw
You can for example install it via conda/mamba using the conda-forge channel as follows. The answer from Yagiz Degirmenci does not work because the conda package in the channel mlgill is only compatible with Python 3.5 and that's deprecated.
The following works:
conda install -c conda-forge powerlaw
Pip should also work:
pip install powerlaw

Dlib library is not installing on Anaconda

I need to install dlib library on my Anaconda and this page in the image doesn't show any thing. Even when I use
pip install dlib
It doesn't install.
you can install via conda channels by using following command on anaconda prompt,
conda install -c conda-forge dlib=19.17
version is depends upon you #obadeji

How do I install the "sparse_dot_topn" Package in Anaconda Installer?

I am trying to install the "sparse_dot_topn" package in Alibaba Cloud ECS instance. Firstly I tried to install it through the Anaconda installer.
conda install sparse_dot_topn
It throws like there is no package available
So I tried to install via pip
Pip install spare_dot_topn
But it throws me the following error
What am I missing? Please leave your suggestions
sparse_dot_topn requires Cython, try installing it this way:
pip install cython
pip install git+https://github.com/ing-bank/sparse_dot_topn.git
I have tried it first with pip install and failed. Then I tried within Anaconda terminal with the following comment and it was succesfull.
conda install -c conda-forge sparse_dot_topn

Problems pip installing Box2D

I'm learning Reinforcement learning and I'm having the following errors.
Error(1) = I can't set up the 'CarRacing-v0' gym environment without Box2D
Error(2) = I can't pip install the Box2D module.
Does someone know how to interpret these errors and help me fix this?
Edit:
When trying to pip install box2d-py I get this error:
Mac users should try:
brew install swig
pip install box2d-py
pip install box2d
terminates without errors under macOS Mojave (10.14)
Windows users need to do as follows:
Download SWIG with the prebuilt executable and extract somewhere on your PC. Please note: I don't think SWIG 4.0 is compatible with Box2D yet, at time of writing SWIG 3.0.12 must be used.
Add the SWIG directory containing swig.exe to system PATH environment variable.
Install Microsoft Visual C++ 14.0. Get it with "Microsoft Visual C++ Build Tools".
pip install box2d
pip install box2d-py
Based on gym's setup.py, it appears that the Box2D it is trying to import comes from the optional dependency box2d-py, so you need to run pip install box2d-py.
For Ubuntu 18.04, the following solved my problem with gym and lunar lander :
pip3 install box2d-py
For Ubuntu 20.04.3, I had to run the following:
sudo apt-get install swig build-essential python-dev python3-dev
before installing box2d-py.
I know this does not solve the problem but after trying for an entire day I ended up running the game using Google Colab Notebooks. Only problem with that is it's a bit hard to render the screen but there is a post on the topic here.
pip install Box2D
it will work 100%

How can I install mayavi on Windows for python 3 via conda?

I have a python 3 virtual environment managed by conda on Windows. I want to install the mayavi package via
conda install mayavi
but it says it requires python 2.7.
Have your luck with a mayavi package available on other channels, by searching on the Anaconda website.
As of today, the one maintained on the conda-forge channel is compatible with python 3.5 and 3.6. To install it,
conda install -c conda-forge mayavi
If mayavi fails with an
ImportError: Could not import backend for traits
it may be because qt is not installed or that qt5 is installed -- in that case it needs to be downgraded
conda install pyqt=4
Here is something you can try:
If you have Visual Studio installed, and Python Native Development Tools installed.
In Anaconda3, you can get VTK7.1.x from clinicalgraphics
conda install -c clinicalgraphics vtk
Open up the VS20xx x64 Native Command Prompt, setting up PATH for python properly:
e.g.
C:\Anaconda3\Scripts\activate.bat C:\Anaconda3
Then install mayavi using pip from source.
pip install mayavi
It compiles successfully with VS2017 and Python 3.6 in windows 10.

Categories

Resources