Git Product home page Git Product logo

Comments (12)

twiecki avatar twiecki commented on June 5, 2024

@ferrine any idea?

from gelato.

ferrine avatar ferrine commented on June 5, 2024

I think that can be caused by our changing flags in context. You can try to set compute_test_value='raise'

from gelato.

twiecki avatar twiecki commented on June 5, 2024

@ferrine that didn't help.

from gelato.

ferrine avatar ferrine commented on June 5, 2024

Ok I'll rerun it on weekends

from gelato.

ferrine avatar ferrine commented on June 5, 2024

It worked

from gelato.

twiecki avatar twiecki commented on June 5, 2024

Now getting a different error:

---------------------------------------------------------------------------
AttributeError                            Traceback (most recent call last)
~/anaconda/lib/python3.6/site-packages/theano/gof/op.py in __call__(self, *inputs, **kwargs)
    624                 try:
--> 625                     storage_map[ins] = [self._get_test_value(ins)]
    626                     compute_map[ins] = [True]

~/anaconda/lib/python3.6/site-packages/theano/gof/op.py in _get_test_value(cls, v)
    580         detailed_err_msg = utils.get_variable_trace_string(v)
--> 581         raise AttributeError('%s has no test value %s' % (v, detailed_err_msg))
    582 

AttributeError: AdvancedSubtensor1.0 has no test value  
Backtrace when that variable is created:

  File "/Users/twiecki/anaconda/lib/python3.6/site-packages/ipykernel/kernelbase.py", line 235, in dispatch_shell
    handler(stream, idents, msg)
  File "/Users/twiecki/anaconda/lib/python3.6/site-packages/ipykernel/kernelbase.py", line 399, in execute_request
    user_expressions, allow_stdin)
  File "/Users/twiecki/anaconda/lib/python3.6/site-packages/ipykernel/ipkernel.py", line 196, in do_execute
    res = shell.run_cell(code, store_history=store_history, silent=silent)
  File "/Users/twiecki/anaconda/lib/python3.6/site-packages/ipykernel/zmqshell.py", line 533, in run_cell
    return super(ZMQInteractiveShell, self).run_cell(*args, **kwargs)
  File "/Users/twiecki/anaconda/lib/python3.6/site-packages/IPython/core/interactiveshell.py", line 2698, in run_cell
    interactivity=interactivity, compiler=compiler, result=result)
  File "/Users/twiecki/anaconda/lib/python3.6/site-packages/IPython/core/interactiveshell.py", line 2802, in run_ast_nodes
    if self.run_code(code, result):
  File "/Users/twiecki/anaconda/lib/python3.6/site-packages/IPython/core/interactiveshell.py", line 2862, in run_code
    exec(code_obj, self.user_global_ns, self.user_ns)
  File "<ipython-input-3-d01dfc616598>", line 6, in <module>
    target_var = target_var[ridx]


During handling of the above exception, another exception occurred:

ValueError                                Traceback (most recent call last)
<ipython-input-18-7dd01309b711> in <module>()
     44                    prediction,
     45                    observed=target_var,
---> 46                    total_size=total_size)

~/working/projects/pymc/pymc3/distributions/distribution.py in __new__(cls, name, *args, **kwargs)
     37             total_size = kwargs.pop('total_size', None)
     38             dist = cls.dist(*args, **kwargs)
---> 39             return model.Var(name, dist, data, total_size)
     40         else:
     41             raise TypeError("Name needs to be a string but got: {}".format(name))

~/working/projects/pymc/pymc3/model.py in Var(self, name, dist, data, total_size)
    543                 var = ObservedRV(name=name, data=data,
    544                                  distribution=dist,
--> 545                                  total_size=total_size, model=self)
    546             self.observed_RVs.append(var)
    547             if var.missing_values:

~/working/projects/pymc/pymc3/model.py in __init__(self, type, owner, index, name, data, distribution, total_size, model)
    958         if type is None:
    959             data = pandas_to_array(data)
--> 960             type = TensorType(distribution.dtype, data.shape)
    961 
    962         self.observations = data

~/anaconda/lib/python3.6/site-packages/theano/tensor/var.py in <lambda>(self)
    273             return theano.tensor.basic.transpose(self, axes)
    274 
--> 275     shape = property(lambda self: theano.tensor.basic.shape(self))
    276 
    277     size = property(lambda self: self.shape[0] if self.ndim == 1 else

~/anaconda/lib/python3.6/site-packages/theano/gof/op.py in __call__(self, *inputs, **kwargs)
    637                         raise ValueError(
    638                             'Cannot compute test value: input %i (%s) of Op %s missing default value. %s' %
--> 639                             (i, ins, node, detailed_err_msg))
    640                     elif config.compute_test_value == 'ignore':
    641                         # silently skip test

ValueError: Cannot compute test value: input 0 (AdvancedSubtensor1.0) of Op Shape(AdvancedSubtensor1.0) missing default value.  
Backtrace when that variable is created:

  File "/Users/twiecki/anaconda/lib/python3.6/site-packages/ipykernel/kernelbase.py", line 235, in dispatch_shell
    handler(stream, idents, msg)
  File "/Users/twiecki/anaconda/lib/python3.6/site-packages/ipykernel/kernelbase.py", line 399, in execute_request
    user_expressions, allow_stdin)
  File "/Users/twiecki/anaconda/lib/python3.6/site-packages/ipykernel/ipkernel.py", line 196, in do_execute
    res = shell.run_cell(code, store_history=store_history, silent=silent)
  File "/Users/twiecki/anaconda/lib/python3.6/site-packages/ipykernel/zmqshell.py", line 533, in run_cell
    return super(ZMQInteractiveShell, self).run_cell(*args, **kwargs)
  File "/Users/twiecki/anaconda/lib/python3.6/site-packages/IPython/core/interactiveshell.py", line 2698, in run_cell
    interactivity=interactivity, compiler=compiler, result=result)
  File "/Users/twiecki/anaconda/lib/python3.6/site-packages/IPython/core/interactiveshell.py", line 2802, in run_ast_nodes
    if self.run_code(code, result):
  File "/Users/twiecki/anaconda/lib/python3.6/site-packages/IPython/core/interactiveshell.py", line 2862, in run_code
    exec(code_obj, self.user_global_ns, self.user_ns)
  File "<ipython-input-3-d01dfc616598>", line 6, in <module>
    target_var = target_var[ridx]

from gelato.

ferrine avatar ferrine commented on June 5, 2024

what is your theano.config.compute_test_value?

from gelato.

twiecki avatar twiecki commented on June 5, 2024

from gelato.

ferrine avatar ferrine commented on June 5, 2024

Could you please git pull and rerun?

from gelato.

ferrine avatar ferrine commented on June 5, 2024

seems like get_output is called without computing test value. Try to set warn in the NB header and rerun

from gelato.

twiecki avatar twiecki commented on June 5, 2024

That did the trick (just pulling), thanks!

from gelato.

ferrine avatar ferrine commented on June 5, 2024

Closed the issue as it seems to be solved

from gelato.

Related Issues (4)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.