{"QuestionId":47086876,"AnswerCount":1,"Tags":"","CreationDate":"2017-11-03T00:58:14.573","AcceptedAnswerId":47086916.0,"OwnerUserId":5411530.0,"Title":"Custom sigmoid activation function","Body":"

So, I'm using Keras to implement a convolutional neural network. At the end of my decoding topology there's a Conv2D layer with sigmoid activation.<\/p>\n\n

<\/pre>\n\n

Basically, I want to change the sigmoid implementation, my goal is to make it a binary-type activation, returning 0 if sigmoid function get values below 0.5 and 1 if it gets values equal or above 0.5.<\/p>\n\n

Searching inside Tensorflow implementations, I found sigmoid's to be something like this:<\/p>\n\n

<\/pre>\n\n

I'm having trouble in manipulating gen_math_ops return, to compare it's values with the 0.5 threshold. I know usual if's can't be used because of tensor-type restrictions, so how should I solve this?<\/p>\n","answers":[{"AnswerId":"47086916","CreationDate":"2017-11-03T01:04:40.620","ParentId":null,"OwnerUserId":"2658050","Title":null,"Body":"

just round your output.<\/p>\n\n

def hardsigmoid(x): \n  return tf.round(tf.nn.sigmoid(x))\n<\/code><\/pre>\n\n

Remember that such hard sigmoid has zero<\/strong> derivatives everywhere so you won't be able to train it with any sort of gradient based technique.<\/p>\n"}]} {"QuestionId":47087475,"AnswerCount":1,"Tags":"","CreationDate":"2017-11-03T02:16:50.503","AcceptedAnswerId":47087685.0,"OwnerUserId":572575.0,"Title":"How to convert value from sklearn MinMaxScaler() back to real value?","Body":"

I use sklearn MinMaxScaler() like this.<\/p>\n\n

<\/pre>\n\n

It change data to range 0-1 . After I predict already it still be value 0-1. How to convert back to real value ?<\/p>\n","answers":[{"AnswerId":"47087685","CreationDate":"2017-11-03T02:44:55.303","ParentId":null,"OwnerUserId":"3374996","Title":null,"Body":"

Use inverse_transform()<\/code><\/a> on the output predicted data.<\/p>\n\n

from sklearn.preprocessing import MinMaxScaler\n\ndata = [[-1, 2], [-0.5, 6], [0, 10], [1, 18]]\nscaler = MinMaxScaler()\nscaler.fit(data)    \n\nprint(scaler.transform([[2, 2]]))\nOut>>> [[ 1.5  0. ]]\n\n\/\/ This is what you need\nprint(scaler.inverse_transform([[ 1.5  0. ]]))\nOut>>> [[ 2.0  2.0]]\n<\/code><\/pre>\n"}]}
{"QuestionId":47088007,"AnswerCount":1,"Tags":"","CreationDate":"2017-11-03T03:22:45.597","AcceptedAnswerId":47088129.0,"OwnerUserId":697065.0,"Title":"Module import works differently for two ways of importing tensorflow","Body":"

I'm currently trying to teach myself tensorflow. The new version has keras built in.<\/p>\n\n

I can access the function in the following way<\/p>\n\n

<\/pre>\n\n

but this does not work:<\/p>\n\n

<\/pre>\n\n

Why is that? I notice that:<\/p>\n\n

<\/pre>\n\n

Does work. When I import tensorflow, does it know to intelligently add the to the module name?<\/p>\n","answers":[{"AnswerId":"47088129","CreationDate":"2017-11-03T03:40:01.220","ParentId":null,"OwnerUserId":"4225229","Title":null,"Body":"

In the GitHub Repo for Tensorflow<\/a>, if you look at the two __init__.py<\/code> files inside tensorflow-master\/tensorflow\/python\/keras\/<\/code> and tensorflow-master\/tensorflow\/python\/keras\/layers\/<\/code>, you can see which modules are imported as part of the package structure. This determines what and how you as a user import things when using the package and its modules.<\/p>\n\n

David Beazley has a really good talk on the innerworkings of this:\nhttps:\/\/www.youtube.com\/watch?v=0oTh1CXRaQ0<\/a><\/p>\n"}]} {"QuestionId":47088775,"AnswerCount":1,"Tags":"","CreationDate":"2017-11-03T05:01:03.150","AcceptedAnswerId":null,"OwnerUserId":6308153.0,"Title":"How can I use three Conv1d on the three axis of my 3*n matrix in Pytorch?","Body":"

The following is my CNN. The input of it is a (3,64) matrix, I want to use three convolution kernels to process the x,y,z axis respectively.<\/p>\n\n

<\/pre>\n\n

But during the running of , a RunTime Error occurs:<\/p>\n\n

\n

RuntimeError: Assertion `cur_target >= 0 && cur_target < n_classes' failed.<\/p>\n<\/blockquote>\n\n

I'm very new to pytorch so that I cannot find out the mistake of my code.\nCan you help me?<\/p>\n","answers":[{"AnswerId":"47117804","CreationDate":"2017-11-05T03:13:02.907","ParentId":null,"OwnerUserId":"6308153","Title":null,"Body":"

The way of convolution is okay. The problem is my labels were between 1 and 13, and the correct range is 0 to 12.\nAfter modifying it, my CNN works successfully.\nBut as a fresher to Pytorch and deep learning, I guess my convolution mode can be clearer and easier. Welcome to point out my errors! <\/p>\n"}]} {"QuestionId":47090056,"AnswerCount":1,"Tags":"","CreationDate":"2017-11-03T06:54:07.437","AcceptedAnswerId":51493156.0,"OwnerUserId":6077443.0,"Title":"Keras LSTM Poor Performance","Body":"

I am trying to build a word prediction system. I have made a lookup table of all unique words and i have converted the words to integers.I have converted each phrase into a time series format. I am feeding this list padded with zero to the lstm network.<\/p>\n\n

<\/pre>\n\n

These are the shape of inp and out and the first and second values of inp and out<\/p>\n\n

<\/pre>\n\n

After the last epoch, this is the accuracy and loss<\/p>\n\n

<\/pre>\n\n

I've tried changing the activation functions to sigmoid and tanh, set back propagation to False,tried adam, adagrad optimizer, altered the number of hidden layers in the network. Also i tried adding softmax to the last layer (I removed it since it was causing Vanishing Gradient Problem). Is the problem with the way i am feeding the data to the network or is it something else ?<\/p>\n","answers":[{"AnswerId":"51493156","CreationDate":"2018-07-24T07:45:00.533","ParentId":null,"OwnerUserId":"6077443","Title":null,"Body":"

I solved the issue by making a lookup table of all unique letters than using a lookup table of unique words. Then i predict the next character until the integer corresponding to space is predicted. Thus predicting the next word or completing the current word.<\/p>\n"}]} {"QuestionId":47090096,"AnswerCount":1,"Tags":"","CreationDate":"2017-11-03T06:56:52.743","AcceptedAnswerId":null,"OwnerUserId":8878855.0,"Title":"Why my training speed in Keras with multi_gpu_model is worse than single gpu?","Body":"

My Keras version is 2.0.9, and using tensorflow backend.<\/p>\n\n

I tried to implement multi_gpu_model<\/a> in keras. However, training with 4 gpus was even worse than 1 gpu in practice. I got 25sec for 1 gpu, and 50sec for 4 gpus. Could you give me the reason why this happens?<\/p>\n\n

\/blog for multi_gpu_model<\/p>\n\n

https:\/\/www.pyimagesearch.com\/2017\/10\/30\/how-to-multi-gpu-training-with-keras-python-and-deep-learning\/<\/a><\/p>\n\n

I used this commend for 1 gpu<\/p>\n\n

<\/pre>\n\n

and for 4 gpus,<\/p>\n\n

<\/pre>\n\n

-Here is source code for training. <\/p>\n\n

<\/pre>\n\n

And this is gpu state with running 4 gpus.<\/a><\/p>\n","answers":[{"AnswerId":"48351389","CreationDate":"2018-01-20T00:26:41.603","ParentId":null,"OwnerUserId":"229998","Title":null,"Body":"

I can give you what I think is the answer, but I don't have it fully working myself. I was tipped off onto this by a bug report<\/a>, but in the source code for multi_gpu_model<\/a> it says:<\/p>\n\n

    # Instantiate the base model (or \"template\" model).\n    # We recommend doing this with under a CPU device scope,\n    # so that the model's weights are hosted on CPU memory.\n    # Otherwise they may end up hosted on a GPU, which would\n    # complicate weight sharing.\n    with tf.device('\/cpu:0'):\n        model = Xception(weights=None,\n                         input_shape=(height, width, 3),\n                         classes=num_classes)\n<\/code><\/pre>\n\n

I think this is the problem. I'm still working on making it work myself, though.<\/p>\n"}]} {"QuestionId":47090964,"AnswerCount":0,"Tags":"","CreationDate":"2017-11-03T08:00:06.143","AcceptedAnswerId":null,"OwnerUserId":8471147.0,"Title":"An error during using graph_frozen.pb in invoke_stepperr of tfdbg","Body":"

OS Platform and Distribution (e.g., Linux Ubuntu 16.04): Linux Ubuntu 16.04.1<\/p>\n\n

TensorFlow installed from (source or binary): binary<\/p>\n\n

TensorFlow version (use command below): tensorflow-gpu (1.1.0)<\/p>\n\n

Python version: 2.7.12<\/p>\n\n

I use this command to frozen my graph and wights:<\/p>\n\n

<\/pre>\n\n

I used graph_frozen.pb in another program. And I got a right result. But when I used tfdbg and invoke_stepper model, I got a very strange error:<\/p>\n\n

<\/pre>\n\n

Why there is a error but I can get a right answer? I can not find the same problem on the Internet. Does anyone have any suggestions on how to fix this?\nThanks in advance.<\/p>\n","answers":[]} {"QuestionId":47091726,"AnswerCount":3,"Tags":"","CreationDate":"2017-11-03T08:56:19.343","AcceptedAnswerId":47096355.0,"OwnerUserId":3214872.0,"Title":"Difference between tf.data.Dataset.map() and tf.data.Dataset.apply()","Body":"

With the recent upgrade to version 1.4, Tensorflow included in the library core.\nOne \"major new feature\" described in the version 1.4 release notes<\/a> is <\/a>, which is a \"method for\napplying custom transformation functions\". How is this different from the already existing <\/a>?<\/p>\n","answers":[{"AnswerId":"47096355","CreationDate":"2017-11-03T12:56:35.270","ParentId":null,"OwnerUserId":"5198595","Title":null,"Body":"

The difference is that map<\/code> will execute one function on every element of the Dataset<\/code> separately, whereas apply<\/code> will execute one function on the whole Dataset<\/code> at once (such as group_by_window<\/code><\/a> given as example in the documentation).<\/p>\n\n

The argument of apply<\/code> is a function that takes a Dataset<\/code> and returns a Dataset<\/code> when the argument of map<\/code> is a function that takes one element and returns one transformed element.<\/p>\n"},{"AnswerId":"47099301","CreationDate":"2017-11-03T15:29:00.180","ParentId":null,"OwnerUserId":"3574081","Title":null,"Body":"

Sunreef's answer<\/a> is absolutely correct. You might still be wondering why<\/em> we introduced Dataset.apply()<\/code><\/a>, and I thought I'd offer some background.<\/p>\n\n

The tf.data<\/code> API has a set of core<\/strong> transformations—like Dataset.map()<\/code> and Dataset.filter()<\/code>—that are generally useful across a wide range of datasets, unlikely to change, and implemented as methods on the tf.data.Dataset<\/code> object. In particular, they are subject to the same backwards compatibility guarantees<\/a> as other core APIs in TensorFlow.<\/p>\n\n

However, the core approach is a bit restrictive. We also want the freedom to experiment with new transformations before adding them to the core, and to allow other library developers to create their own reusable transformations. Therefore, in TensorFlow 1.4 we split out a set of custom<\/strong> transformations that live in tf.contrib.data<\/code>. The custom transformations include some that have very specific functionality (like tf.contrib.data.sloppy_interleave()<\/code><\/a>), and some where the API is still in flux (like tf.contrib.data.group_by_window()<\/code><\/a>). Originally we implemented these custom transformations as functions from Dataset<\/code> to Dataset<\/code>, which had an unfortunate effect on the syntactic flow of a pipeline. For example:<\/p>\n\n

dataset = tf.data.TFRecordDataset(...).map(...)\n\n# Method chaining breaks when we apply a custom transformation.\ndataset = custom_transformation(dataset, x, y, z)\n\ndataset = dataset.shuffle(...).repeat(...).batch(...)\n<\/code><\/pre>\n\n

Since this seemed to be a common pattern, we added Dataset.apply()<\/code> as a way to chain core and custom transformations in a single pipeline:<\/p>\n\n

dataset = (tf.data.TFRecordDataset(...)\n           .map(...)\n           .apply(custom_transformation(x, y, z))\n           .shuffle(...)\n           .repeat(...)\n           .batch(...))\n<\/code><\/pre>\n\n

It's a minor feature in the grand scheme of things, but hopefully it helps to make tf.data<\/code> programs easier to read, and the library easier to extend.<\/p>\n"},{"AnswerId":"47104482","CreationDate":"2017-11-03T21:12:46.113","ParentId":null,"OwnerUserId":"2426955","Title":null,"Body":"

I don't have enough reputation to comment, but I just wanted to point out that you can actually use map to apply to multiple elements in a dataset contrary to @sunreef's comments on his own post. <\/p>\n\n

According to the documentation, map takes as an argument<\/p>\n\n

\n

map_func: A function mapping a nested structure of tensors (having\n shapes and types defined by self.output_shapes and self.output_types)\n to another nested structure of tensors.<\/p>\n<\/blockquote>\n\n

the output_shapes are defined by the dataset and can be modified by using api functions like batch. So, for example, you can do a batch normalization using only dataset.batch and .map with:<\/p>\n\n

dataset = dataset ...\ndataset.batch(batch_size)\ndataset.map(normalize_fn)\n<\/code><\/pre>\n\n

It seems like the primary utility of apply()<\/code> is when you really want to do a transformation across the entire dataset. <\/p>\n"}]} {"QuestionId":47091757,"AnswerCount":1,"Tags":"","CreationDate":"2017-11-03T08:58:10.460","AcceptedAnswerId":null,"OwnerUserId":8733657.0,"Title":"How to do fine-tuning in tensorflow with notop layers and define my own input image size","Body":"

\nThere are many examples about how to do fine-tuning with tensorflow. Almost all these examples are try to resize our images to the specified size that the existing model needs. Like for example, 224\u00d7224 is the input size that vgg19 needs. However, in keras, we can change the input size by setting the include_top to false:<\/p>\n\n

<\/pre>\n\n

Then we do not have to fix the image size to be 224\u00d7224 anymore. Can we do such kind of fine-tuning by using official pre-trained models in tensorflow? I cannot find the solutions up till now, anyone help me?<\/p>\n","answers":[{"AnswerId":"48415464","CreationDate":"2018-01-24T05:36:26.067","ParentId":null,"OwnerUserId":"8357000","Title":null,"Body":"

Yes, it is possible to do this kind of fine-tuning. You would just have to ensure that you also fine-tune some of the first few layers (to account for changed input) of the original network in addition to the last few layers (to account for changed output).<\/p>\n\n

I work with TensorFlow using Keras. If you are open to that, then there is a code snippet that shows the general fine-tuning flow here:<\/p>\n\n

https:\/\/keras.io\/applications\/<\/a><\/p>\n\n

Specifically, I had to write the following code to make it work for my case:<\/p>\n\n

#img_width,img_height is the size of your new input, 3 is the number of channels\ninput_tensor = Input(shape=(img_width, img_height, 3))\nbase_model = \nkeras.applications.vgg19.VGG19(include_top=False,weights='imagenet', input_tensor=input_tensor)\n#instantiate whatever other layers you need\nmodel = Model(inputs=base_model.inputs, outputs=predictions)\n#predictions is the new logistic layer added to account for new classes\n<\/code><\/pre>\n\n

Hope this helps.<\/p>\n"}]} {"QuestionId":47091925,"AnswerCount":0,"Tags":"","CreationDate":"2017-11-03T09:07:15.837","AcceptedAnswerId":null,"OwnerUserId":6329284.0,"Title":"Embedding matrix for seq2seq","Body":"

I have a question about the implementation of LSTMs in Tensorflow\u2026 and especially with the application of seq2seq modelling (where you have an Encoder and Decoder).<\/p>\n\n

In short: Learning a word embedding while using the seq2seq model, aren\u2019t we having redundant weights?<\/strong><\/p>\n\n

A usual approach is to embed the input words (for the encoder) like word2vec vectors, however the modelling approach is also able to learn these embeddings. This means that when we are going to setup the variables for the encoder, we have an additional embedding matrix (outside the LSTM) that encodes our vocabulary.\nWhat my understand of the LSTM node, or let\u2019s take the (simpler) RNN node, is that the following equation is applied<\/p>\n\n

<\/pre>\n\n

Where we have the dimensions <\/p>\n\n

<\/pre>\n\n

The value one (1) here can be replaced by the batch_size I believe. (correct me if Im wrong please)<\/p>\n\n

My worry is around the part. Because in this case, the vector x is already an embedded vector and thus calculating feels redundant\u2026 if x were a one-hot encoded vector, then it would make sense IMO.<\/p>\n\n

Can anyone tell me if my reasoning is sound, and if I am understanding this \u2018extra embedding\u2019 for the seq2seq models correctly.<\/p>\n\n

EDIT: the only thing I can think of now is that you dont want to have the full embedding inside your LSTM for some reason... (why exactly is unclear to me). But I can imagine that you lose some flexibility if you need to set the n_hidden dimension of the LSTM to the vocabulary size. For example.. when your vocabulary size changes... or maybe training effort.. If anyone can confirm this, then that would be great :)<\/p>\n","answers":[]} {"QuestionId":47091950,"AnswerCount":0,"Tags":"","CreationDate":"2017-11-03T09:08:39.510","AcceptedAnswerId":null,"OwnerUserId":8427065.0,"Title":"How can I optimise the weights of CNN using PSO?","Body":"

I want to optimize the weights of CNN using Particle Swarm Optimization. Basically weights are at penultimate layer and filters that are tobe optimised. The PSO replaces the optimisers and rest work is done in same way. Will it be possible by using Keras or Tensorflow? Have written a PSO code that is attached below.<\/p>\n\n

<\/pre>\n","answers":[]}
{"QuestionId":47092185,"AnswerCount":1,"Tags":"","CreationDate":"2017-11-03T09:21:23.897","AcceptedAnswerId":47442005.0,"OwnerUserId":6619344.0,"Title":"TensorFlow Word2Vec model running on GPU","Body":"

In this TensorFlow example<\/a> a training of skip-gram Word2Vec model described. It contains the following code fragment, which explicitly requires CPU device for computations, i.e. :<\/p>\n\n

<\/pre>\n\n

When trying switch to GPU, the following exception is raised:<\/p>\n\n

\n

InvalidArgumentError<\/strong> (see above for traceback): Cannot assign a device for operation 'Variable_2\/Adagrad': Could not satisfy explicit device specification '\/device:GPU:0' because no supported kernel for GPU devices is available.<\/p>\n<\/blockquote>\n\n

I wonder what is the reason why the provided graph cannot be computed on GPU? Does it happen due to type? Or should I switch to another optimizer? In other words, is there any way to make possible processing Word2Vec model on GPU? (Without types casting).<\/p>\n\n


\n\n

UPDATE<\/strong><\/p>\n\n

Following Akshay Agrawal recommendation, here is an updated fragment of the original code that achieves required result:<\/p>\n\n

<\/pre>\n","answers":[{"AnswerId":"47442005","CreationDate":"2017-11-22T18:55:44.753","ParentId":null,"OwnerUserId":"8858032","Title":null,"Body":"

The error is raised because AdagradOptimizer<\/code> does not have a GPU kernel for its sparse apply operation; a sparse apply is triggered because differentiating through the embedding lookup results in a sparse gradient. <\/p>\n\n

GradientDescentOptimizer<\/code> and AdamOptimizer<\/code> do support sparse apply operations. If you were to switch to one of these optimizers, you would unfortunately see another error: tf.nn.sampled_softmax_loss appears to create an op that does not have a GPU kernel. To get around that, you could wrap the loss = tf.reduce_mean(...<\/code> line with a with tf.device('\/cpu:0'):<\/code> context, though doing so would introduce cpu-gpu communication overhead.<\/p>\n"}]} {"QuestionId":47092626,"AnswerCount":4,"Tags":"","CreationDate":"2017-11-03T09:44:34.990","AcceptedAnswerId":47177306.0,"OwnerUserId":6833276.0,"Title":"How to reduce the number of training steps in Tensorflow's Object Detection API?","Body":"

I am following Dat Trans<\/a> example to train my own Object Detector with TensorFlow\u2019s Object Detector API.
<\/p>\n\n

I successfully started to train the custom objects. I am using CPU to train the model but it takes around 3 hour to complete 100 training steps. I suppose i have to change some parameter in .

\nI tried to convert to , I referred
this<\/a> post, but i was still not able to convert<\/p>\n\n

1) How to reduce the number of training steps?
\n2) Is there a way to convert to .<\/p>\n","answers":[{"AnswerId":"47092775","CreationDate":"2017-11-03T09:51:31.033","ParentId":null,"OwnerUserId":"3214872","Title":null,"Body":"

1) I'm afraid there is no effective way to just \"reduce\" training steps. Using bigger batch sizes may<\/em> lead to \"faster\" training (as in, reaching high accuracy in a lower number of steps<\/strong>), but each step will take longer<\/strong> to compute, since you're running on your CPU.\nPlaying around with input image resolution might give you a speedup, to the price of lower accuracy.\nYou should really consider moving to a machine with a GPU.<\/p>\n\n

2) .pb<\/code> files (and their corresponding text version .pbtxt<\/code>) by default contain only the definition of your graph. If you freeze<\/em> your graph, you take a checkpoint, get all the variables defined in the graph, convert them to constants and assign them the values stored in the checkpoint. You typically do this to ship your trained<\/strong> model to whoever will use it, but this is useless in the training stage.<\/p>\n"},{"AnswerId":"47126447","CreationDate":"2017-11-05T20:45:07.463","ParentId":null,"OwnerUserId":"8229032","Title":null,"Body":"

I would highly recommend finding a way to speed up your per-training-step running time rather than reducing the number of training steps. The best way is to get your hands on a GPU. If you can't do this, you can look into reducing image resolution or using a lighter network.<\/p>\n\n

For converting to a frozen inference graph (the .pb file), please see the documentation here:\nhttps:\/\/github.com\/tensorflow\/models\/blob\/master\/research\/object_detection\/g3doc\/exporting_models.md<\/a><\/p>\n"},{"AnswerId":"47131062","CreationDate":"2017-11-06T06:32:32.083","ParentId":null,"OwnerUserId":"8323207","Title":null,"Body":"

Ya there is one parameter in the .config file where you can reduce the number of step as much you want. num_steps: is in .config file which is actually number of epochs in training. <\/p>\n\n

But please keep in mind that it is not recommended to reduce it much.Because if you reduce it much your loss function will not be reduce much which will give you bad output.<\/p>\n\n

So keep seeing loss function, once it come under 1 , then you can start testing your model seprately and your training will be happening.<\/p>\n"},{"AnswerId":"47177306","CreationDate":"2017-11-08T10:30:44.537","ParentId":null,"OwnerUserId":"4359558","Title":null,"Body":"

I don't think you can reduce the number of training step, but you can stop at any checkpoint(ckpt<\/code>) and then convert it to .pb<\/code> file
\nFrom TensorFlow Model git repository you can use ,
export_inference_graph.py<\/a>\n
\nand following code<\/p>\n\n

python tensorflow_models\/object_detection\/export_inference_graph.py \\\n--input_type image_tensor \\\n--pipeline_config_path architecture_used_while_training.config \\\n--trained path_to_saved_ckpt\/model.ckpt-NUMBER \\\n--output_directory model\/\n<\/code><\/pre>\n\n

where NUMBER<\/code> refers to your latest saved checkpoint file number, however you can use older checkpoint file if you find it better in tensorboard<\/p>\n"}]} {"QuestionId":47092750,"AnswerCount":0,"Tags":"","CreationDate":"2017-11-03T09:50:17.060","AcceptedAnswerId":null,"OwnerUserId":8879442.0,"Title":"Keras\/TF Recurrent Layers (GRU, LSTM) Freezing Kernel on Initialization","Body":"

On my machine at home, I am running into a problem that does not occur on my work machine. Specifically, Python freezes and locks up the kernel (which I can't even interrupt) on initializing a recurrent layer of moderate size.<\/p>\n\n

A minimal reproducible example follows:<\/p>\n\n

<\/pre>\n\n

The same thing happens when I try it with an LSTM instead of a GRU. (Ignore if you will the apparent oddness of using a recurrent layer with input that has a single time step.)<\/p>\n\n

When it freezes, it just runs forever. (It might<\/em> stop at some point, but I always kill everything before it does.) The fan eventually groans as though it's doing some real work. I notice no significant draw on available RAM. I also noticed that TensorFlow by this point has allocated no memory on the GPU. CPU load, on the other hand, shoots up to about 400% (this is an eight-core machine).<\/p>\n\n

I recently installed TensorFlow 1.4 via pip, but this is loading 1.3 on a Python 3.6 kernel. A few stray points:<\/p>\n\n