insct icon indicating copy to clipboard operation
insct copied to clipboard

Allow user to set cpu cores used

Open davemcg opened this issue 4 years ago • 1 comments

https://github.com/lkmklsmn/insct/blob/master/tnn/tnn.py#L39

As far as I can see TNN uses all available cores.

Don't want the HPC people angry.

davemcg avatar May 19 '20 18:05 davemcg

As a quick solution (which I havent tested myself). You could try running import tensorflow as tf import keras config = tf.ConfigProto(device_count={"CPU": 3}) keras.backend.tensorflow_backend.set_session(tf.Session(config=config)) before you train the model.

lkmklsmn avatar May 19 '20 18:05 lkmklsmn