Quantcast

Error creating abstract Symfun in Sybolic Package with Pytave

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
6 messages Options
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Error creating abstract Symfun in Sybolic Package with Pytave

NVS Abhilash
I was just trying something out by using Pytave with Symbolic package, where I got this error..

```
sympref ipc native
syms f(x)

error: pyexec: error in return value type conversion
error: called from
    subsref at line 58 column 9
    subsref at line 56 column 7
    check_and_convert at line 46 column 5
    python_ipc_native at line 104 column 5
    python_ipc_driver at line 55 column 13
    python_cmd at line 164 column 9
    sym at line 396 column 19
    syms at line 169 column 9

```

Is this behavior known yet? Because in default ipc it works just fine..
NVS Abhilash
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Error creating abstract Symfun in Sybolic Package with Pytave

Colin Macdonald-2
On 15/03/17 09:19 AM, NVS Abhilash wrote:

> I was just trying something out by using Pytave with Symbolic package, where
> I got this error..
>
> ```
> sympref ipc native
> syms f(x)
>
> error: pyexec: error in return value type conversion
> error: called from
>     subsref at line 58 column 9
>     subsref at line 56 column 7
>     check_and_convert at line 46 column 5
>     python_ipc_native at line 104 column 5
>     python_ipc_driver at line 55 column 13
>     python_cmd at line 164 column 9
>     sym at line 396 column 19
>     syms at line 169 column 9
>
> ```
>
> Is this behavior known yet? Because in default ipc it works just fine..

Hmmm, I'm not sure!  Maybe file a new issue while we track it down?  If
you run "octsympy_tests" do any other tests fail?

Colin

_______________________________________________
Help-octave mailing list
[hidden email]
https://lists.gnu.org/mailman/listinfo/help-octave
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Error creating abstract Symfun in Sybolic Package with Pytave

NVS Abhilash
Colin Macdonald-2 wrote
Hmmm, I'm not sure!  Maybe file a new issue while we track it down?  If
you run "octsympy_tests" do any other tests fail?
I have actually asked for a similar concern here:
http://octave.1599824.n4.nabble.com/GSoC-2017-Symbolic-Package-td4682073.html#a4682293

And yes some tests are failing, I am not sure about the number, it is giving 47 now.. gave 56 before. I don't know why it changed.

It might be my machine's problem. Maybe you can confirm it and then we can open the issue maybe.

Thanks,
NVS
NVS Abhilash
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Error creating abstract Symfun in Sybolic Package with Pytave

Colin Macdonald-2
On 15/03/17 11:21 AM, NVS Abhilash wrote:
> It might be my machine's problem. Maybe you can confirm it and then we can
> open the issue maybe.

Hi yes, I think I have that error too, using octsympy git master and
Octave recent hg.  Can you help narrow it down?

Colin

_______________________________________________
Help-octave mailing list
[hidden email]
https://lists.gnu.org/mailman/listinfo/help-octave
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Error creating abstract Symfun in Sybolic Package with Pytave

NVS Abhilash
Colin Macdonald-2 wrote
Hi yes, I think I have that error too, using octsympy git master and
Octave recent hg.  Can you help narrow it down?
I tried to debug the code so that I can find where the error is happening.

It seems the error was called in the catch block of *pycall.cc* in Pytave.

I ran
```
syms x
f(x) = sym('f(x)')
```

This is what pycall was called with when the error happened:

In @pyobject/subsref.m at line 58
58:       r = pycall (x, t.subs{:});

where
disp (x) gave
<built-in function isinstance>

t.subs contained
subs =
    {
      [1,1] =

     

      [1,2] =

     

    }
Where [1, 1] was pyobject 'f(x)'
and [1, 2] was (<class 'sympy.core.basic.Basic'>, <class 'sympy.matrices.matrices.MatrixBase'>)

I am now trying to debug the Pytave .cc files maybe we can narrow it further then.

Thanks,
NVS
NVS Abhilash
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Error creating abstract Symfun in Sybolic Package with Pytave

Colin Macdonald-2
On 17/03/17 01:39 AM, NVS Abhilash wrote:
> I am now trying to debug the Pytave .cc files maybe we can narrow it further
> then.

Thanks!  I've filed [1] in Pytave, b/c I can reproduce this without
Octsympy.

I haven't had a chance to check yet, but its likely that Octsympy from
early November 2016 avoids this issue: I haven't checked yet.  For
example, after 5ed387bec29f30423449d5a487e56fb0596954f7 there were major
changes to sym.

[1]
https://bitbucket.org/mtmiller/pytave/issues/79/sympy-function-objects-cause-errors

Colin

_______________________________________________
Help-octave mailing list
[hidden email]
https://lists.gnu.org/mailman/listinfo/help-octave
Loading...