tensorflow-workshop | use TensorFlow to build | Machine Learning library
kandi X-RAY | tensorflow-workshop Summary
kandi X-RAY | tensorflow-workshop Summary
How to use TensorFlow to build a convolutional neural network for classifying handwritten digits (MNIST).
Support
Quality
Security
License
Reuse
Top functions reviewed by kandi - BETA
- Evaluate the mnist classifier
- Preprocess the data from my hand written in the data folder
tensorflow-workshop Key Features
tensorflow-workshop Examples and Code Snippets
Community Discussions
Trending Discussions on tensorflow-workshop
QUESTION
Hei, I got an error when running code for Alexnet feature extraction. I createalexnet.pb
file using this github link. I checked using Tensorboard and the graph went well.
I want to use this model to extract feature from fc7/relu
and feed it to another model. I create the graph using this:
ANSWER
Answered 2018-Feb-28 at 11:55This line:
QUESTION
I have been unable to figure out how to use transfer learning/last layer retraining with the new TF Estimator API.
The Estimator
requires a model_fn
which contains the architecture of the network, and training and eval ops, as defined in the documentation. An example of a model_fn
using a CNN architecture is here.
If I want to retrain the last layer of, for example, the inception architecture, I'm not sure whether I will need to specify the whole model in this model_fn
, then load the pre-trained weights, or whether there is a way to use the saved graph as is done in the 'traditional' approach (example here).
This has been brought up as an issue, but is still open and the answers are unclear to me.
...ANSWER
Answered 2018-Jan-11 at 16:13It is possible to load the metagraph during model definition and use SessionRunHook to load the weights from a ckpt file.
QUESTION
When using google cloud ML to train models:
The official examples https://github.com/GoogleCloudPlatform/cloudml-samples/blob/master/census/tensorflowcore/trainer/task.py uses hooks, is_client, MonitoredTrainingSession and some other complexity.
Is this required for cloud ml or is using this example enough: https://github.com/amygdala/tensorflow-workshop/tree/master/workshop_sections/wide_n_deep?
The documentation is a bit limited in terms of best practices and optimisation, will GCP ML handle the client/worker mode or do we need to set devices e.g. replica_device_setter
and so on?
ANSWER
Answered 2017-May-09 at 20:21CloudML Engine is largely agnostic to how you write your TensorFlow programs. You provide a Python program, and the service executes it for you, providing it with some environment variables you can use to perform distributed training (if necessary), e.g., task index, etc.
census/tensorflowcore demonstrates how to do things with the "core" TensorFlow library -- how to do everything "from scratch", including using replica_device_setters
, MonitoredTrainingSessions
, etc.. This may be necessary sometimes for ultimate flexibility, but can be tedious.
Alongside the census/tensorflowcore example, you'll also see a sample called census/estimator. This example is based on a higher level library, which unfortunately is in contrib
and therefore does not yet have a fully stable API (expect lots of deprecation warnings, etc.). Expect it to stabilize in a future version of TensorFlow.
That particularly library (known as Estimators
) is a higher level API that takes care of a lot of the dirty work for you. It will parse TF_CONFIG
for you and setup the replica_device_setter
as well as handle the MonitoredTrainingSession
and necessary Hook
s, while remaining fairly customizable.
This is the same library that the wide and deep example you pointed to is based on and they are fully supported on the service.
Community Discussions, Code Snippets contain sources that include Stack Exchange Network
Vulnerabilities
No vulnerabilities reported
Install tensorflow-workshop
Support
Reuse Trending Solutions
Find, review, and download reusable Libraries, Code Snippets, Cloud APIs from over 650 million Knowledge Items
Find more librariesStay Updated
Subscribe to our newsletter for trending solutions and developer bootcamps
Share this Page