ysharma HF Staff commited on
Commit
ad64176
·
verified ·
1 Parent(s): 9a9513f

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +9 -1
app.py CHANGED
@@ -3,9 +3,17 @@ import tempfile
3
  from PIL import Image
4
  import os
5
 
 
 
 
 
 
6
  # Access the environment variable
7
  print(os.environ['GRADIO_TEMP_DIR'])
8
-
 
 
 
9
  def create():
10
  """
11
  Create a blank image with the specified dimensions, color, and filename.
 
3
  from PIL import Image
4
  import os
5
 
6
+ # Assuming 'my_directory' is a directory in the current working directory
7
+ directory_name = 'temp_dir'
8
+ absolute_path1 = os.path.abspath(directory_name)
9
+ print(f"The absolute path of '{directory_name}' is: {absolute_path1}")
10
+
11
  # Access the environment variable
12
  print(os.environ['GRADIO_TEMP_DIR'])
13
+ dir1 = os.environ['GRADIO_TEMP_DIR']
14
+ absolute_path1 = os.path.abspath(dir1)
15
+ print(f"The absolute path of '{dir1}' is: {absolute_path1}")
16
+
17
  def create():
18
  """
19
  Create a blank image with the specified dimensions, color, and filename.