Skip to content

Cannot create a Normal distribution with carl 0.2, Theano 0.8.2 #60

Open
@gnperdue

Description

@gnperdue

Hello,

I am attempting to test this library, but running into problems quickly. The versions of relevant libraries I have are:

$ python pyverchecker.py
Python version: 2.7.13 |Continuum Analytics, Inc.| (default, Dec 20 2016, 23:05:08)
[GCC 4.2.1 Compatible Apple LLVM 6.0 (clang-600.0.57)]
pandas version: 0.19.2
matplotlib version: 2.0.0
numpy version: 1.12.0
scipy version: 0.19.0
IPython version: 5.3.0
sklearn version: 0.18
pymc3 version: 3.0
theano version: 0.8.2
carl version: 0.2
h5py version: 2.6.0

If I try to instantiate a Normal, I get:

(py2th) ~$ ipython
Python 2.7.13 |Continuum Analytics, Inc.| (default, Dec 20 2016, 23:05:08)
Type "copyright", "credits" or "license" for more information.

IPython 5.3.0 -- An enhanced Interactive Python.
?         -> Introduction and overview of IPython's features.
%quickref -> Quick reference.
help      -> Python's own help system.
object?   -> Details about 'object', use 'object??' for extra details.

In [1]: from carl.distributions import Normal

In [2]: pnorm = Normal(mu=0.0, sigma=1.0)
ERROR (theano.gof.opt): Optimization failure due to: local_mul_canonizer
ERROR (theano.gof.opt): node: Elemwise{true_div,no_inplace}(Elemwise{mul,no_inplace}.0, Elemwise{pow,no_inplace}.0)
ERROR (theano.gof.opt): TRACEBACK:
ERROR (theano.gof.opt): Traceback (most recent call last):
  File "/Users/gnperdue/anaconda/envs/py2th/lib/python2.7/site-packages/theano/gof/opt.py", line 1772, in process_node
    replacements = lopt.transform(node)
  File "/Users/gnperdue/anaconda/envs/py2th/lib/python2.7/site-packages/theano/tensor/opt.py", line 4505, in transform
    new = self.merge_num_denum(num, denum)
  File "/Users/gnperdue/anaconda/envs/py2th/lib/python2.7/site-packages/theano/tensor/opt.py", line 4327, in merge_num_denum
    return self.inverse(self.merge_num_denum(num, []),
  File "/Users/gnperdue/anaconda/envs/py2th/lib/python2.7/site-packages/theano/tensor/opt.py", line 4326, in merge_num_denum
    return self.main(*num)
  File "/Users/gnperdue/anaconda/envs/py2th/lib/python2.7/site-packages/theano/gof/op.py", line 633, in __call__
    (i, ins, node))
ValueError: Cannot compute test value: input 1 (Elemwise{pow,no_inplace}.0) of Op Elemwise{mul,no_inplace}(DimShuffle{x,x}.0, Elemwise{pow,no_inplace}.0) missing default value

There is actually a long spew of errors, all ending in ValueErrors that complain about "missing default values."

Any suggestions?

Thanks!

pax
Gabe

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions