Skip to content

Error log with Baseball example on GPU #2032

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
springcoil opened this issue Apr 14, 2017 · 6 comments
Closed

Error log with Baseball example on GPU #2032

springcoil opened this issue Apr 14, 2017 · 6 comments
Labels

Comments

@springcoil
Copy link
Contributor

I think this is probably not surprising.

But I get

    transformed_name, transform.apply(distribution), total_size=total_size)
  File "/home/ubuntu/miniconda3/envs/bunnies/lib/python3.5/site-packages/pymc3/model.py", line 508, in Var
    total_size=total_size, model=self)
  File "/home/ubuntu/miniconda3/envs/bunnies/lib/python3.5/site-packages/pymc3/model.py", line 800, in __init__
    self.logp_elemwiset = distribution.logp(self)
  File "/home/ubuntu/miniconda3/envs/bunnies/lib/python3.5/site-packages/pymc3/distributions/transforms.py", line 74, in logp
    return (self.dist.logp(self.transform_used.backward(x)) +
  File "/home/ubuntu/miniconda3/envs/bunnies/lib/python3.5/site-packages/pymc3/distributions/transforms.py", line 145, in backward
    r = tt.exp(x) + a
  File "/home/ubuntu/miniconda3/envs/bunnies/lib/python3.5/site-packages/theano/gof/op.py", line 625, in __call__
    storage_map[ins] = [self._get_test_value(ins)]
  File "/home/ubuntu/miniconda3/envs/bunnies/lib/python3.5/site-packages/theano/gof/op.py", line 562, in _get_test_value
    ret = v.type.filter(v.tag.test_value)
  File "/home/ubuntu/miniconda3/envs/bunnies/lib/python3.5/site-packages/theano/tensor/type.py", line 173, in filter
    raise TypeError(err_msg, data)
TypeError: For compute_test_value, one input test value does not have the requested type.

The error when converting the test value to that variable type:
TensorType(float32, scalar) cannot store accurately value 0.693043224656, it would be represented as 0.6930432319641113. If you do not mind this precision loss, you can: 1) explicitly convert your data to a numpy array of dtype float32, or 2) set "allow_input_downcast=True" when calling "function".```
When running the baseball example on a gpu. I'll run a few more in the examples folders just to see what they say. 
@springcoil springcoil added the bug label Apr 14, 2017
@springcoil
Copy link
Contributor Author

springcoil commented Apr 14, 2017

cc #2033

@springcoil springcoil changed the title Error with Baseball example on GPU Error log with Baseball example on GPU Apr 14, 2017
@twiecki
Copy link
Member

twiecki commented Apr 14, 2017

Make sure to cast your input data to float32.

@springcoil
Copy link
Contributor Author

I'm pretty sure that's the solution. I'll try it out soon.

@springcoil
Copy link
Contributor Author

cc #2035 -- still getting errors.

@twiecki
Copy link
Member

twiecki commented Apr 14, 2017

Same float64 errors?

@springcoil
Copy link
Contributor Author

Seems to be caused by some tt.log applications - I'll run pdb :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants