Numerically Stable Tensorflow - tensorflow

Tensorflow has been used to compute images but I want to use Tensorflow to compute Biological Models. However, the biological model requires big division and this causes numerical instability. I want to have TensorFlow that supports more numerically stability. Are there any hacks to allow Tensorflow to be more numerically stable? I will follow up with more codes in the near feature but if there are any options please tell me.

Please refer to the below paper on Tensorflow Distributions and see if it helps answer your question.
https://arxiv.org/pdf/1711.10604.pdf
If not, please elaborate your issue.
Mention any code snippet of what you have tried, or any limitations you faced while implementing your model.

Related

can anybody suggest a package for neural ode for tensorflow?

I tried this : https://github.com/titu1994/tfdiffeq,
but had an issue and cannot proceed further - https://github.com/titu1994/tfdiffeq/issues/10
Tensorflow Probability has differentiable ODE solvers here.
You will get used to TFP solvers soon because the interface is much similar to tfdiffeq.
(But it also has some issues and I'm having trouble toošŸ˜„)

fast.ai equivalent in tensorflow

Is there any equivalent/alternate library to fastai in tensorfow for easier training and debugging deep learning models including analysis on results of trained model in Tensorflow.
Fastai is built on top of pytorch looking for similar one in tensorflow.
The obvious choice would be to use tf.keras.
It is bundled with tensorflow and is becoming its official "high-level" API -- to the point where in TF 2 you would probably need to go out of your way not using it at all.
It is clearly the source of inspiration for fastai to easy the use of pytorch as Keras does for tensorflow, as mentionned by the authors time and again:
Unfortunately, Pytorch was a long way from being a good option for part one of the course, which is designed to be accessible to people with no machine learning background. It did not have anything like the clear simple API of Keras for training models. Every project required dozens of lines of code just to implement the basics of training a neural network. Unlike Keras, where the defaults are thoughtfully chosen to be as useful as possible, Pytorch required everything to be specified in detail. However, we also realised that Keras could be even better. We noticed that we kept on making the same mistakes in Keras, such as failing to shuffle our data when we needed to, or vice versa. Also, many recent best practices were not being incorporated into Keras, particularly in the rapidly developing field of natural language processing. We wondered if we could build something that could be even better than Keras for rapidly training world-class deep learning models.

K-means clustering algorithm in TensorFlow

I was looking for the k-means clustering algorithm in TensorFlow. Does anyone know if TensorFlow has support for it?
Here you have it: https://www.tensorflow.org/api_docs/python/tf/contrib/factorization/KMeansClustering.
It may also be helpful: https://www.tensorflow.org/api_docs/python/tf/contrib/factorization/KMeans.
Note that all code under tf.contrib is volatile or experimental. Furthermore, note that you could easily have found what I did using the search box in the TensorFlow website.

tensorflow embedding projector t-sne algorithm difference from other implementation?

I've been playing with the tensorflow standalone embedding projector (http://projector.tensorflow.org/) and found it a very helpful tool for visualization. However, when I try to replicate the t-sne result using other implementations (e.g., Rtsne, sklearn.manifold.tsne), the low dimension projection seems to be very different. Particularly, the clusters are much more spread-out in the embedding projector than that learnt using R or python packages.
I used the same perplexity, learning rate and momentum parameters. And tried both spherizing or not spherizing the data as implied in the projector.
Could anyone help to shed light on the difference between the tensorflow projector implementation of the t-sne algorithm and other implementations like Rtsne? For example, is there a similar 'exaggeration' parameter used in the projector as in Rtsne? What is the optimization algorithm? Or is there anything special in generating the visualization?
I believe the source code of the tensorflow projector is the oss_demo_bin.js file in https://github.com/tensorflow/embedding-projector-standalone. Unfortunately I'm not familiar with javascript and found it hard to interpret.
Thanks!

How to predict using Tensorflow?

This is a newbie question for the tensorflow experts:
I reading lot of data from power transformer connected to an array of solar panels using arduinos, my question is can I use tensorflow to predict the power generation in future.
I am completely new to tensorflow, if can point me to something similar I can start with that or any github repo which is doing similar predictive modeling.
Edit: Kyle pointed me to the MNIST data, which I believe is a Image Dataset. Again, not sure if tensorflow is the right computation library for this problem or does it only work on Image datasets?
thanks, Rajesh
Surely you can use tensorflow to solve your problem.
TensorFlowā„¢ is an open source software library for numerical
computation using data flow graphs.
So it works not only on Image dataset but also others. Don't worry about this.
And about prediction, first you need to train a model(such as linear regression) on you dataset, then predict. The tutorial code can be found in tensorflow homepage .
Get your hand dirty, you will find it works on your dataset.
Good luck.
You can absolutely use TensorFlow to predict time series. There are plenty of examples out there, like this one. And this is a really interesting one on using RNN to predict basketball trajectories.
In general, TF is a very flexible platform for solving problems with machine learning. You can create any kind of network you can think of in it, and train that network to act as a model for your process. Depending on what kind of costs you define and how you train it, you can build a network to classify data into categories, predict a time series forward a number of steps, and other cool stuff.
There is, sadly, no short answer for how to do this, but that's just because the possibilities are endless! Have fun!