Code Monkey home page Code Monkey logo

Comments (1)

hrlai avatar hrlai commented on August 26, 2024 1

Okay this is weirdly timely because the following also failed on me this morning. Using the same example as above:

library(greta)

x <- rnorm(10)
mu <- normal(0, 5)
sigma <- lognormal(1, 0.1)
distribution(x) <- normal(mu, sigma)
m <- model(mu, sigma)

draws <- mcmc(m, n_samples = 2000, thin = 2, one_by_one = TRUE)

This errors:

 tensorflow error:
Error in py_call_impl(callable, dots$args, dots$keywords):
tensorflow.python.framework.errors_impl.UnimplementedError: TensorArray has size zero, but
element shape [?] is not fully defined. Currently only static shapes are supported when
packing zero-size TensorArrays. <... omitted ...>gather(math_ops.range(0, self.size()),
name=name) File "/tensorflow/python/ops/tensor_array_ops.py", line 323, in gather
element_shape=element_shape) File "/tensorflow/python/ops/gen_data_flow_ops.py", line 6705, in
tensor_array_gather_v3 element_shape=element_shape, name=name) File
"/tensorflow/python/framework/op_def_library.py", line 788, in _apply_op_helper op_def=op_def)
File "/tensorflow/python/util/deprecation.py", line 507, in new_func return func(*args,
**kwargs) File "/tensorflow/python/framework/ops.py", line 3616, in create_op op_def=op_def)
File "/tensorflow/python/framework/ops.py", line 2005, in __init__ self._traceback =
tf_s
Error in trace_list_batches[[1]] : subscript out of bounds

Note that this n_samples is a multiple of thin here, but one_by_one = TRUE seems to break things...

from greta.

Related Issues (20)

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.