These are chat archives for symengine/symengine

20th
Oct 2017
Siddhartha Rao Kamalakara
@srk97
Oct 20 2017 13:09
Hey everyone, I'd like to contribute to symengine. Could someone tell me where I can start? I see that the docs are being developed, I can contribute to that as well.
Shikhar Jaiswal
@ShikharJ
Oct 20 2017 22:19

@isuruf I was reinstalling SymEngine.pyon my new system and got the following error:

python2
Python 2.7.14 (default, Sep 23 2017, 22:06:14) 
[GCC 7.2.0] on linux2
Type "help", "copyright", "credits" or "license" for more information.
>>> import symengine
>>> from symengine import var
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
ImportError: cannot import name var
>>> from symengine import symbols
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
ImportError: cannot import name symbols

This is weird, because when I first ran this code, it worked. But after I closed the terminal and tried running it again I got this.

Isuru Fernando
@isuruf
Oct 20 2017 22:27
@ShikharJ, in which directory are running this from?
Shikhar Jaiswal
@ShikharJ
Oct 20 2017 22:29
No directory. Straight from terminal.
Isuru Fernando
@isuruf
Oct 20 2017 22:30
In the terminal move to a new empty folder and try again
Shikhar Jaiswal
@ShikharJ
Oct 20 2017 22:31
That worked!
Isuru Fernando
@isuruf
Oct 20 2017 22:33
Don't start the python process from a terminal with cwd having a folder called symengine
Shikhar Jaiswal
@ShikharJ
Oct 20 2017 22:35
Also, is it possible to import SymEngine in a live shell of isympy?
Isuru Fernando
@isuruf
Oct 20 2017 22:36
what does "live shell of isympy" mean?
Shikhar Jaiswal
@ShikharJ
Oct 20 2017 22:37
I meant the IPython console for SymPy.
Isuru Fernando
@isuruf
Oct 20 2017 22:38
You can import in IPython. there's nothing special there
Shikhar Jaiswal
@ShikharJ
Oct 20 2017 22:39
I am having an issue there as well:
shikhar@shikhar-XPS-15-9560:~/tempo$ isympy
IPython console for SymPy 1.1.2.dev (Python 2.7.14-64-bit) (ground types: python)

These commands were executed:
>>> from __future__ import division
>>> from sympy import *
>>> x, y, z, t = symbols('x y z t')
>>> k, m, n = symbols('k m n', integer=True)
>>> f, g, h = symbols('f g h', cls=Function)
>>> init_printing()

Documentation can be found at http://docs.sympy.org/dev


In [1]: import symengine
---------------------------------------------------------------------------
ImportError                               Traceback (most recent call last)
<ipython-input-1-78609076377c> in <module>()
----> 1 import symengine

ImportError: No module named symengine

In [2]: from symengine import *
---------------------------------------------------------------------------
ImportError                               Traceback (most recent call last)
<ipython-input-2-2162d346543d> in <module>()
----> 1 from symengine import *

ImportError: No module named symengine
Isuru Fernando
@isuruf
Oct 20 2017 22:39
did you install symengine to the correct environment?
In isympy, run import sys; print(sys.prefix)
is that same when you run it in normal pythonshell?
Shikhar Jaiswal
@ShikharJ
Oct 20 2017 22:43
The output is usr/ for isympy and /home/shikhar/miniconda3 for python.
Isuru Fernando
@isuruf
Oct 20 2017 22:44
then install ipython for the miniconda environment
Shikhar Jaiswal
@ShikharJ
Oct 20 2017 22:44
All right.