How to install packages/modules in IronPython - python

I am new to IronPython. Thanks for you help and patience.
I installed IronPython 2.7 from http://ironpython.net/ in Visual Studio 2015.
I also installed Python 2.7.6 and anaconda.
I tried the following solution and it didn't work. Installing Python Packages - IronPython
I am wondering can IronPython use the modules installed by anaconda directly?
The packages I tried to install are numpy,scipy,pandas,sklearn. I saw a document in 2012 pointed out that sklearn is not supported in IronPython. Is it still the case?
Thanks.

depend on IronPython official website http://ironpython.net/blog/2014/12/07/pip-in-ironpython-275.html
you can follow the following steps
Step1
add path of ironPython installation to system path
Step2
run cmd as administrator and type the following command
ipy -X:Frames -m ensurepip
now you can install everything is done, you can simply add any package by following command
ipy -X:Frames -m pip install Package

Related

No module named open3d

I am trying to compile a python program (by running "python file.py"), but it gives me the error of "No module named open3d". I have installed open3d on my Mac system using "pip3 install open3d-python". I am also running python 3.10.4 64 bit.
I reinstalled python 3.10 and that comes with pip, so I am pretty sure that when I use pip to install packages they go in the same place. My vscode also doesn't show any errors when I am interpreting using 3.10, unlike 3.9 where there are yellow squiggles below my import line.
I have looked at other posts about a module not found but their fixes don't seem to work for me.
open3d library is currently not available for python version 3.10. I am solve it by installing with python 3.8.
The supported environment for open3d:
Supported Python versions:
3.6
3.7
3.8
3.9
Supported operating systems:
Ubuntu 18.04+
macOS 10.15+
Windows 10 (64-bit)
If you have other Python versions or operating systems, please refer to Build from source and compile Open3D from source.
Why did you install open3d with pip3 install open3d-python?
The official instruction gives pip3 install open3d.
Did you run your python via python in cmd? Maybe trying python3 could help.
pip install open3d work for me.

Why is my Mac using python 2.7 when I have 3.8 already installed?

I'm trying to install Selenium using pip. But when I go to my editor (pycharm CE running on 3.8) no such module exists. When I type python -version on terminal it comes up with python 2.7 with a deprecation warning. How to I change this? I'm pretty sure I have to change my path or something like that, but how? Any help is greatly appreciated.
That's because python2.7 is installed by default on Mac. Python3.8 is probably installed besides 2.7. Use python3.8 command and python3.8 -m pip install selenium to install selenium for this specific python version. If pip is not installed for python3.8, install it the official way.
Don't replace system python, because that might break your OS.

python3 pip fails to install jupyter on windows 10

I want to install jupyter on Win 10. I have been using python on linux, but this is my first time on Win 10.
when I execute python -m pip install jupyter on administrator, I got errors like this:
The package setup script has attempted to modify files on your system
that are not within the EasyInstall build area, and has been aborted.
This package cannot be safely installed by EasyInstall, and may not
support alternate installation locations even if you run its setup
script by hand. Please inform the package's author and the EasyInstall
maintainers to find out if a fix or workaround is available.
any idea?
I have been able to get around this error by installing Anaconda, uninstalling Python 3.8.0 and installing Python 3.7.5 instead.
The Jupyter installation then ran successfully when I executed pip install jupyter with Git Bash in my C:\ drive using pip 19.2.3 (the default with Python 3.7.5).
For those who encounter this and need to use Python 3.8+, make sure to update you setuptools to version 42.0.0 (or later).
Install a version earlier than python 3.8 and the installation will work. Use CMD.
I had the same problem, I am using 64-bit windows 10 but downloaded the 32-bit python installer because it is the default that appears on the 'downloads' page on the python.org site. Uninstalled python 3.8.1, downloaded the 64-bit installer instead, and then ran 'pip install jupyterlab' using the pip version 19.2.3 that got installed with the 64-bit python instead of upgrading to pip version 19.3.1. So if you are running a 64-bit version of windows, make sure you download the 64-bit python installer!

unable to install pymorph

I'm trying to install 'pymorph' on mac os x with 'PIP':
sudo pip install pymorph
I'm getting the following error:
NameError: name 'execfile' is not defined
Command "python setup.py egg_info" failed with error code 1 in
/private/tmp/pip-build-9hjd5tfm/pymorph/
I have read that using a python version different from 2.7 could lead to this kind of problem. Yet, I'm using the 2.7 version:
python --version
Python 2.7.13
Any ideas to solve this issue ?
Thank you in advance
It's possible to have a pip command on your PATH that comes from a different Python installation than the python command. (Each entry script to a Python-based tool is bound to the Python installation that was used to install the package that provided it. This means that the pip command does not search PATH for a python installation.) If this pip comes up later on PATH than python, it would lead to behaviour that you describe.
This can happen, say, if you first install a Python 2.7 without pip, and then a Python 3.x with pip, if the installers prepend to PATH.
You can verify which version of Python pip is using and where it's installed by running pip -V.
The robust solution to this should be using a virtual environment that lets you tie the base python installation and libraries specific to your application alone with your project, as well as avoid cluttering your global site-packages, and prevent inadvertent compatibility issues from different versions of the same package being needed by different projects.
It seems that the current (as of late 2017) recommended virtual environment solution is Pipenv. A decent-looking introduction to virtual environments using Pipenv, by the author of Pipenv, can be found here.

Python3.3 can't find libpython3.3m.so in linux (pip-3.3)

I'm using ubuntu 12.10 with default python3.2. However I downloaded python 3.3 as its much more polished. Of course, since then I have a nightmare with installing modules for 3.3, as python3 packages from synaptic install to 3.2 dir. So, I installed pip using python 3.3. Now I have pip-3.3 command, great. But, when I tried "sudo pip-3.3 install PySide" I quickly got an error: "error: Failed to locate the Python library /usr/lib/libpython3.3m.so". What's more, when I run "sudo pip install PySide" (command for 2.7), it builded and installed and runs flawlessy. Pyvenv and virtualenv both fail too. But I wan't to do it non-env way,just install pyside to global 3.3 lib dir.
So how can I install that PySide to python 3.3? I just can't get it to work... It looks like I will have to stick with default ubuntu python 3 version (this one runs great, everything works both from pip and synaptic), but I like to use newest python as it gets better and better with every release.
Btw, if that matters I also got following warning before that error:
"package init file 'PySide/init.py' not found (or not a regular file)" and
"package init file 'pysideuic/init.py' not found (or not a regular file)"
Edit: I installed full python3.3 from synaptic, including pythoh3.3-dev, debug, lib etc. Everything.
And that dynamic python 3.3 lib exist in /usr/lib/x86_64-linux-gnu/libpython3.3m.so, maybe just python3.3 package for ubuntu is poor and installs it in wrong direction/doesn't do any symlinks tricks?
Please try this answer installing from source (PySide). Download pyside sources and install from source, follow the instructions on the link.

Categories

Resources