tensorflow / tensorflow/probability

Cholesky decomposition was not successful. The input might not be valid.

Open
#1,306 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Jupyter Notebook
Stars
4.4k
Forks
1.1k
PR merge metrics
No merged PRs in 30d

Description

Please make sure that this is a bug. As per our
GitHub Policy,
we only address code/doc bugs, performance issues, feature requests and
build/installation issues on GitHub. tag:bug_template

System information

  • Have I written custom code (as opposed to using a stock example script provided in TensorFlow): No
  • OS Platform and Distribution (e.g., Linux Ubuntu 16.04): Windows 10
  • Mobile device (e.g. iPhone 8, Pixel 2, Samsung Galaxy) if the issue happens on mobile device:
  • TensorFlow installed from (source or binary): binary
  • TensorFlow version (use command below): 2.5.0rc0
  • Python version: 3.8.8
  • Bazel version (if compiling from source):
  • GCC/Compiler version (if compiling from source):
  • CUDA/cuDNN version: tried with 11.1/11.2 same issue (cudnn 8.1.1.33)
  • GPU model and memory: RTX3080 10GB

You can collect some of this information using our environment capture
script
You can also obtain the TensorFlow version with:

  1. TF 1.0: python -c "import tensorflow as tf; print(tf.GIT_VERSION, tf.VERSION)"
  2. TF 2.0: python -c "import tensorflow as tf; print(tf.version.GIT_VERSION, tf.version.VERSION)"
    v1.12.1-53831-ga8b6d5ff93a 2.5.0-rc0

Describe the current behavior
I was trying to run the sample code from TFP homepage (https://blog.tensorflow.org/2019/03/structural-time-series-modeling-in.html)
I ran this in google colab its fully working.
But when I ran in my own Jupyter it gives error "Cholesky decomposition was not successful. The input might not be valid." when I reached the code component_dists = sts.decompose_by_component( co2_model, observed_time_series=co2_by_month, parameter_samples=q_samples_co2_)

When I run the forecast tfp.sts.forecast the result is different with the colab result significantly too.

Describe the expected behavior
The result from colab is same pretty much the same with the result shown on the webpage. I expect the result from the code running in my pc should be the same too.

Standalone code to reproduce the issue
Provide a reproducible test case that is the bare minimum necessary to generate
the problem. If possible, please share a link to Colab/Jupyter/any notebook.

https://github.com/tensorflow/probability/blob/master/tensorflow_probability/examples/jupyter_notebooks/Structural_Time_Series_Modeling_Case_Studies_Atmospheric_CO2_and_Electricity_Demand.ipynb

Other info / logs Include any logs or source code that would be helpful to
diagnose the problem. If including tracebacks, please include the full
traceback. Large logs and files should be attached.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by running the linked Structural_Time_Series_Modeling_Case_Studies_Atmospheric_CO2_and_Electricity_Demand.ipynb locally with the reported TensorFlow 2.5.0rc0, Python 3.8.8, Windows 10, and GPU setup. Compare the component_dists call and tfp.sts.forecast results with Colab, then use the full traceback and environment details to identify the discrepancy. Done means the local notebook reproduces the expected behavior or documents a confirmed cause.

Written by the indexing model from the issue text.

Assessment

Tech stack
jupyter-notebook, python, tensorflow
Domain
data, machine-learning
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.