firagne commited on
Commit
a5f5c9f
·
verified ·
1 Parent(s): 6ebf7d2

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +3 -2
app.py CHANGED
@@ -11,15 +11,16 @@ from huggingface_hub import hf_hub_download
11
  import uuid
12
  import traceback
13
 
 
14
  embed_html1 = '<iframe width="560" height="315" src="https://www.youtube.com/embed/'
15
  embed_html2 = '" title="YouTube video player" frameborder="0" allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture" allowfullscreen></iframe>'
16
  # NO GPU
17
  #os.environ['CUDA_VISIBLE_DEVICES'] = '-1'
18
  os.environ['TF_CPP_MIN_LOG_LEVEL'] = '3'
19
- #import tensorflow
20
  #tensorflow.config.threading.set_intra_op_parallelism_threads(8)
21
  #tensorflow.config.threading.set_inter_op_parallelism_threads(8)
22
-
23
  #
24
  python_path = hf_hub_download(repo_id=os.environ['REPO_ID'], repo_type="space", filename=os.environ['MODEL_FILE'],
25
  use_auth_token=os.environ['TOKEN'])
 
11
  import uuid
12
  import traceback
13
 
14
+
15
  embed_html1 = '<iframe width="560" height="315" src="https://www.youtube.com/embed/'
16
  embed_html2 = '" title="YouTube video player" frameborder="0" allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture" allowfullscreen></iframe>'
17
  # NO GPU
18
  #os.environ['CUDA_VISIBLE_DEVICES'] = '-1'
19
  os.environ['TF_CPP_MIN_LOG_LEVEL'] = '3'
20
+ import tensorflow
21
  #tensorflow.config.threading.set_intra_op_parallelism_threads(8)
22
  #tensorflow.config.threading.set_inter_op_parallelism_threads(8)
23
+ print(tf.config.list_physical_devices('GPU'))
24
  #
25
  python_path = hf_hub_download(repo_id=os.environ['REPO_ID'], repo_type="space", filename=os.environ['MODEL_FILE'],
26
  use_auth_token=os.environ['TOKEN'])