tensorboard

Tensorboard Graph with custom training loop does not include my Model

强颜欢笑 提交于 2020-04-18 05:48:58
问题 I have created my own loop as shown in the TF 2 migration guide here. I am currently able to see the graph for only the --- VISIBLE --- section of the code below. How do I make my model (defined in the ---NOT VISIBLE--- section) visible in tensorboard? If I was not using a custom training loop, I could have gone with the documented model.fit approach : model.fit(..., callbacks=[keras.callbacks.TensorBoard(log_dir=logdir)]) In TF 1, the approach used to be quite straightforward: tf.compat.v1

Tensorboard for custom training loop in Tensorflow 2

≯℡__Kan透↙ 提交于 2020-04-16 02:29:31
问题 I want to create a custom training loop in tensorflow 2 and use tensorboard for visualization. Here is an example I've created based on tensorflow documentation: import tensorflow as tf import datetime os.environ["CUDA_VISIBLE_DEVICES"] = "0" # which gpu to use mnist = tf.keras.datasets.mnist (x_train, y_train), (x_test, y_test) = mnist.load_data() x_train, x_test = x_train / 255.0, x_test / 255.0 train_dataset = tf.data.Dataset.from_tensor_slices((x_train, y_train)) test_dataset = tf.data

Tensorboard for custom training loop in Tensorflow 2

穿精又带淫゛_ 提交于 2020-04-16 02:27:22
问题 I want to create a custom training loop in tensorflow 2 and use tensorboard for visualization. Here is an example I've created based on tensorflow documentation: import tensorflow as tf import datetime os.environ["CUDA_VISIBLE_DEVICES"] = "0" # which gpu to use mnist = tf.keras.datasets.mnist (x_train, y_train), (x_test, y_test) = mnist.load_data() x_train, x_test = x_train / 255.0, x_test / 255.0 train_dataset = tf.data.Dataset.from_tensor_slices((x_train, y_train)) test_dataset = tf.data

Keras and TensorBoard - AttributeError: 'Sequential' object has no attribute '_get_distribution_strategy'

五迷三道 提交于 2020-03-26 03:53:08
问题 I am using keras and trying to plot the logs using tensorboard. Bellow you can find out the error I am getting and also the list of packages versions I am using. I can not understand it is giving me the error of 'Sequential' object has no attribute '_get_distribution_strategy'. Package: Keras 2.3.1 Keras-Applications 1.0.8 Keras-Preprocessing 1.1.0 tensorboard 2.1.0 tensorflow 2.1.0 tensorflow-estimator 2.1.0 MODEL: model = Sequential() model.add(Embedding(MAX_NB_WORDS, EMBEDDING_DIM, input

Merging 2 plots in TensorBoard 2 with TensorFlow 2

余生颓废 提交于 2020-03-25 19:08:23
问题 I would like to merge on the same plot both the precision and recall using Tensorflow and tensorboard V2. I found many examples for the previous versions, but none of them is working in my case. I have created a Keras callback that calculates the precision and recall, then I call a tensorflow summary to log them in the same logger. I can visualize them in Tensorboard, but in 2 separated plots. Class ClassificationReport(Callback): def __init__(self, data_generator, steps, label_names, log

Merging 2 plots in TensorBoard 2 with TensorFlow 2

妖精的绣舞 提交于 2020-03-25 19:06:45
问题 I would like to merge on the same plot both the precision and recall using Tensorflow and tensorboard V2. I found many examples for the previous versions, but none of them is working in my case. I have created a Keras callback that calculates the precision and recall, then I call a tensorflow summary to log them in the same logger. I can visualize them in Tensorboard, but in 2 separated plots. Class ClassificationReport(Callback): def __init__(self, data_generator, steps, label_names, log

Overfitting in Tensorflow Object detection API

自古美人都是妖i 提交于 2020-03-23 09:53:04
问题 I am training tensorflow object detection API model on the custom dataset i.e. License plate dataset. My goal is to deploy this model to the edge device using tensorflow lite so I can't use any RCNN family model . Because, I can't convert any RCNN family object detection model to tensorflow lite model (this is the limitation from tensorflow object detection API). I am using ssd_mobilenet_v2_coco model to train the custom dataset. Following is the code snippet of my config file: model { ssd {

unable to use Trained Tensorflow model

风格不统一 提交于 2020-02-19 05:07:21
问题 I am new to Deep Learning and Tensorflow. I retrained a pretrained tensorflow inceptionv3 model as saved_model.pb to recognize different type of images but when I tried to use the fie with below code. with tf.Session() as sess: with tf.gfile.FastGFile("tensorflow/trained/saved_model.pb",'rb') as f: graph_def = tf.GraphDef() tf.Graph.as_graph_def() graph_def.ParseFromString(f.read()) g_in=tf.import_graph_def(graph_def) LOGDIR='/log' train_writer=tf.summary.FileWriter(LOGDIR) train_writer.add

unable to use Trained Tensorflow model

百般思念 提交于 2020-02-19 05:07:07
问题 I am new to Deep Learning and Tensorflow. I retrained a pretrained tensorflow inceptionv3 model as saved_model.pb to recognize different type of images but when I tried to use the fie with below code. with tf.Session() as sess: with tf.gfile.FastGFile("tensorflow/trained/saved_model.pb",'rb') as f: graph_def = tf.GraphDef() tf.Graph.as_graph_def() graph_def.ParseFromString(f.read()) g_in=tf.import_graph_def(graph_def) LOGDIR='/log' train_writer=tf.summary.FileWriter(LOGDIR) train_writer.add

tensorflow Found more than one graph event per run

一个人想着一个人 提交于 2020-01-29 07:11:05
问题 I am loading a tensorboard for my ml engine experiment that is running in local mode and got the following warning: "Found more than one graph event per run, or there was a metagraph containing a graph_def, as well as one or more graph events. Overwriting the graph with the newest event. W0825 19:26:12.435613 Reloader event_accumulator.py:311] Found more than one metagraph event per run. Overwriting the metagraph with the newest event." Originally, I suspected that this was because I had not