Giter VIP home page Giter VIP logo

fatigue_cvae's People

Contributors

mylonasc avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar

fatigue_cvae's Issues

kl_div problem

Hello, I encountered some issues when running your code. Below is the error message. I think it might be due to some configuration or environment problems. May I ask what your environment configuration was when you ran this code? Thank you.


TypeError Traceback (most recent call last)
Cell In[40], line 4
2 cond_size = w_norm.shape[-1]
3 nlatent = 30
----> 4 cvae = CVAEModel( cond_size,input_dims, nlatent, layer_width=300)
7 def eval_loss(X,W, beta = 0.1 ):
8 Xhat ,z_out, kl_loss = cvae.vae_model([X,W])

Cell In[35], line 70
66 vae_params = self.encoder(X_in)
68 posterior_out = posterior(tf.keras.layers.concatenate(vae_params))
---> 70 kl_div = tfd.kl_divergence(tfd.MultivariateNormalDiag(loc = vae_params[0], scale_diag=vae_params[1] ), prior)
72 self.posterior_out = posterior_out
74 dec_output = input_dims

File c:\Users\A\anaconda3\envs\BB\lib\site-packages\tensorflow_probability\python\distributions\kullback_leibler.py:100, in kl_divergence(distribution_a, distribution_b, allow_nan_stats, name)
98 with distribution_a._name_and_control_scope(name + "_a"):
99 with distribution_b._name_and_control_scope(name + "_b"):
--> 100 kl_t = kl_fn(distribution_a, distribution_b, name=name)
101 if allow_nan_stats:
102 return kl_t

File c:\Users\A\anaconda3\envs\BB\lib\site-packages\tensorflow_probability\python\distributions\mvn_linear_operator.py:397, in _kl_brute_force(a, b, name)
391 else:
...
---> 70 raise e.with_traceback(filtered_tb) from None
71 finally:
72 del filtered_tb

TypeError: Dimension value must be integer or None or have an index method, got value '<attribute 'shape' of 'numpy.generic' objects>' with type '<class 'getset_descriptor'>'

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.