diff --git a/object_tracker.py b/object_tracker.py index 3e37d4b2..5a18d8e4 100644 --- a/object_tracker.py +++ b/object_tracker.py @@ -5,6 +5,7 @@ import tensorflow as tf physical_devices = tf.config.experimental.list_physical_devices('GPU') if len(physical_devices) > 0: + tf.config.experimental.set_visible_devices(physical_devices[0], 'GPU') tf.config.experimental.set_memory_growth(physical_devices[0], True) from absl import app, flags, logging from absl.flags import FLAGS