ipython与python支持python3.5吗

ipython - Python 3.x on python(x,y)? - Stack Overflow
to customize your list.
Stack Overflow is a community of 4.7 million programmers, just like you, helping each other.
J it only takes a minute:
Join the Stack Overflow community to:
Ask programming questions
Answer and help your peers
Get recognized for your expertise
I'm in the process of setting up a Matlab like environment so I downloaded the latest version of python(x,y) with all the modules that come with it and downloaded python 3.4.1. Does python(x,y) not run the latest version of python? I noticed because the python(x,y) shell doesn't auto calculate mathematical operations into floats which
I read is a difference between python 2.x and 3.x. Do I just have to wait for a new release of (x,y) or am I missing something here?
3,94941428
You can make Python 2 behave the same as Python 3 w.r.t. division with t
from __future__ import division
Imports from __future__ should be the in the top of the file. There is probably a way to auto-load this expression (I know it is possible in IPython) but I'm not familiar with python(x,y).
16.7k11535
For learning more about Python do the tutorials available via python.org. The latest version of Python3 is recommend.
Since you are in a transition process, take a look at SciPy () and Sage ().
These might be a better fit for the problems you need to solve.
If you do a lot of interactive work at the terminal, take a look at ipython ().
Regarding the division operator is defaults to integer division in Python2, but will be just normal division in Python3.
You can change this by using the -Q flag when starting the interpreter.
(Do: python --help)
For example:
$ python2.7 -Qnew
Python 2.7.6 (default, Nov 18 :51)
[GCC 4.2.1 Compatible Apple LLVM 5.0 (clang-500.2.79)] on darwin
Type "help", "copyright", "credits" or "license" for more information.
$ python2.7
Python 2.7.6 (default, Nov 18 :51)
[GCC 4.2.1 Compatible Apple LLVM 5.0 (clang-500.2.79)] on darwin
Type "help", "copyright", "credits" or "license" for more information.
$ python3.4
Python 3.4.1 (default, May 21 :38)
[GCC 4.2.1 Compatible Apple LLVM 5.1 (clang-503.0.40)] on darwin
Type "help", "copyright", "credits" or "license" for more information.
Yes, python(x, y) is . Just download Python and pip and you can get all of the packages in python(x, y) for yourself -- there's nothing special about it.
5,80011038
Your Answer
Sign up or
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Post as a guest
By posting your answer, you agree to the
Not the answer you're looking for?
Browse other questions tagged
Stack Overflow works best with JavaScript enabledPython-3.5.2
Python-3.5.2
Introduction to Python 3
The Python 3 package contains the
Python development environment.
This is useful for object-oriented programming, writing scripts,
prototyping large programs or developing entire applications.
This package is known to build and work properly using an LFS-7.9
This package is known to build properly using the gcc-6 compiler.
Package Information
Download (HTTP):
Download MD5 sum: 8906efbacfcdc7c3c9198aeefafd159e
Download size: 15 MB
Estimated disk space required: 360 MB ( additional
23 MB for the tests)
Estimated build time: 1.1 SBU (additional 1.9 SBU for the
Additional Downloads
Optional HTML Documentation
Download (HTTP):
Python 3 Dependencies
Recommended
(required for some tests), and
Optional (For Additional Modules)
User Notes:
Installation of Python 3
Install Python 3 by running the
following commands:
CXX="/usr/bin/g++"
./configure --prefix=/usr
--enable-shared
--with-system-expat \
--with-system-ffi
--without-ensurepip &&
The test suite must be run separately, using an X terminal (see
Now, as the root user:
make install &&
chmod -v 755 /usr/lib/libpython3.5m.so &&
chmod -v 755 /usr/lib/libpython3.so
If you have downloaded the preformatted documentation from
install it as the root user:
install -v -dm755 /usr/share/doc/python-3.5.2/html &&
tar --strip-components=1 \
--no-same-owner \
--no-same-permissions \
-C /usr/share/doc/python-3.5.2/html \
-xvf ../python-3.5.2-docs-html.tar.bz2
The test suite must be run separately from the build, either before
or after the package is built and installed. Do not run
make install, after
running the test suite. To build and install the package, you need
to start with a fresh or clean source tree. For the test, you also
need a clean source code, so either start by removing the source
code directory and starting over, by uncompressing the source
tarball or by running make
clean. Then configure again, adding
&--with-pydebug& to the
configure switches
above, run make, then
make test. Remember
that tests must be executed using an X terminal. One test fails for
unknown reasons.
Command Explanations
CXX="/usr/bin/g++" ./configure
...: Avoid an annoying message during
configuration.
--with-system-expat: This switch
enables linking against system version of Expat.
--with-system-ffi: This switch enables
linking against system version of libffi. Remove if you have not installed
recommended dependency .
--with-dbmliborder=bdb:gdbm:ndbm: Use
this switch if you want to build Python DBM Module against Berkeley DB instead of GDBM.
--without-ensurepip: This
switch disables building pip and setuptools packaging programs.
chmod ...: Fix
permissions for shared libraries to be consistent with other
libraries.
Configuring Python 3
In order for python3
to find the installed documentation, create the following version
independent symlink:
ln -svfn python-3.5.2 /usr/share/doc/python-3
and add the following environment variable to the individual user's
or system's profile:
export PYTHONDOCS=/usr/share/doc/python-3/html
Installed Programs:
2to3 (symlink), 2to3-3.5, pydoc3
(symlink), pydoc3.5, python3 (symlink); python3.5 and
python3.5m (hardlinked); python3-config (symlink),
python3.5-config (symlink), python3.5m-config, pyvenv
(symlink), pyvenv-3.5, idle3 (symlink), and idle3.5
Installed Libraries:
libpython3.5m.so and libpython3.so
Installed Directories:
/usr/include/python3.5m,
/usr/lib/python3.5, and /usr/share/doc/python-3.5.2
Short Descriptions
is a wrapper script that opens a Python aware GUI editor. For this
script to run, you must have installed Tk before Python so that the Tkinter
Python module is built.
is the Python
documentation tool.
is an interpreted, interactive, object-oriented
programming language.
is a version-specific name for the python program.
creates virtual Python
environments in one or more target directories.ipython 最好用的交互python环境
ipython 最好用的交互python环境
[摘要:ipython 比平凡python shell轻易良多。比方 用 ?变量名 就可以间接挨出赞助. 支撑tab主动补完 主动缩进 间接履行shell敕令. 应用 ! 把返回效果间接放进变量.比方 c=!ps 便把ps敕令效果间接放到c中]
ipython 比普通python shell方便很多。比如用 ?变量名 就能直接打出帮助.支持tab自动补完自动缩进直接执行shell命令.使用 ! 把返回结果直接放入变量.比如 c=!ps 就把ps命令结果直接放到c中.然后就可以直接操作了最好的功能是使用 ipython -p pysh 命令可以打开python shell.这就是一个python语言的shell.终于可以使用python直接操作shell了.感觉舒服很多.
感谢关注 Ithao123精品文库频道,是专门为互联网人打造的学习交流平台,全面满足互联网人工作与学习需求,更多互联网资讯尽在 IThao123!
Laravel是一套简洁、优雅的PHP Web开发框架(PHP Web Framework)。它可以让你从面条一样杂乱的代码中解脱出来;它可以帮你构建一个完美的网络APP,而且每行代码都可以简洁、富于表达力。
Hadoop是一个由Apache基金会所开发的分布式系统基础架构。
用户可以在不了解分布式底层细节的情况下,开发分布式程序。充分利用集群的威力进行高速运算和存储。
Hadoop实现了一个分布式文件系统(Hadoop Distributed File System),简称HDFS。HDFS有高容错性的特点,并且设计用来部署在低廉的(low-cost)硬件上;而且它提供高吞吐量(high throughput)来访问应用程序的数据,适合那些有着超大数据集(large data set)的应用程序。HDFS放宽了(relax)POSIX的要求,可以以流的形式访问(streaming access)文件系统中的数据。
Hadoop的框架最核心的设计就是:HDFS和MapReduce。HDFS为海量的数据提供了存储,则MapReduce为海量的数据提供了计算。
产品设计是互联网产品经理的核心能力,一个好的产品经理一定在产品设计方面有扎实的功底,本专题将从互联网产品设计的几个方面谈谈产品设计
随着国内互联网的发展,产品经理岗位需求大幅增加,在国内,从事产品工作的大部分岗位为产品经理,其实现实中,很多从事产品工作的岗位是不能称为产品经理,主要原因是对产品经理的职责不明确,那产品经理的职责有哪些,本专题将详细介绍产品经理的主要职责
IThao123周刊Using Ipython With Python3 - 推酷
Using Ipython With Python3
I started to move along with using python 3, and for the sake of using it, wanted my python shell for to be working properly, now you must have been aware, I use ipython for most of my python work, so while I downloaded and installed python3. I was unable to use ipython. The
pip3 install ipython3
didn’t came of much help. Technicall, I am having two versions of python running on to my system, one is the native python version
which by default came with my OS, other python version
which I had explicity downloaded for using python3.
Googling around did helped me, and the solution was pretty simple for implementation.
$ which ipython
/usr/local/bin/ipython
$ which python3
/usr/local/bin/python3
cp /usr/local/bin/ipython /usr/local/bin/ipython3
edit the ipython3 file.
#!/usr/local/bin/python
# -*- coding: utf-8 -*-
import sys
from IPython import start_ipython
if __name__ == '__main__':
sys.argv[0] = re.sub(r'(-script\.pyw|\.exe)?$', '', sys.argv[0])
sys.exit(start_ipython())
Change the shebang which is
#!/usr/local/bin/python
#!/usr/local/bin/python3
Save the file.
run ipython3, I am assuming
/usr/local/bin
is in the system path.
Python 3.5.1 (v3.5.1:37a07cee5969, Dec
Type &copyright&, &credits& or &license& for more information.
IPython 4.2.0 -- An enhanced Interactive Python.
-& Introduction and overview of IPython's features.
%quickref -& Quick reference.
-& Python's own help system.
-& Details about 'object', use 'object??' for extra details.
What we basically did, was copied the original ipython file which was being used by python version 2 and ensured that to work with python3 by changing its shebang line, which tells ipython to use the desired python version. In case, if you do not already have ipython installed then
pip install ipython
will just work, post your python 3 installation.
已发表评论数()
请填写推刊名
描述不能大于100个字符!
权限设置: 公开
仅自己可见
正文不准确
标题不准确
排版有问题
没有分页内容
图片无法显示
视频无法显示
与原文不一致}

我要回帖

更多关于 python ipython 的文章

更多推荐

版权声明:文章内容来源于网络,版权归原作者所有,如有侵权请点击这里与我们联系,我们将及时删除。

点击添加站长微信