Pavan2k4 commited on
Commit
246dc17
·
verified ·
1 Parent(s): b3ce201

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +5 -7
app.py CHANGED
@@ -87,13 +87,12 @@ def save_to_hf_repo(local_path, repo_path):
87
  st.exception(e)
88
 
89
 
90
- BASE_DIR = os.getcwd()
91
 
92
  # Define subdirectories
93
- UPLOAD_DIR = "uploaded_images"
94
- MASK_DIR = "generated_masks"
95
- PATCHES_DIR = "patches"
96
- PRED_PATCHES_DIR = "pred_patches"
97
  CSV_LOG_PATH = "image_log.csv"
98
 
99
  # Create directories
@@ -229,8 +228,7 @@ def upload_page():
229
  filepath = os.path.join(UPLOAD_DIR, filename)
230
  converted_filepath = os.path.join(UPLOAD_DIR, converted_filename)
231
 
232
- with open(filepath, "wb") as f:
233
- f.write(bytes_data)
234
 
235
 
236
  #st.success(f"Image saved to {filepath}")
 
87
  st.exception(e)
88
 
89
 
90
+
91
 
92
  # Define subdirectories
93
+ UPLOAD_DIR = "Images"
94
+ MASK_DIR = "Masks"
95
+
 
96
  CSV_LOG_PATH = "image_log.csv"
97
 
98
  # Create directories
 
228
  filepath = os.path.join(UPLOAD_DIR, filename)
229
  converted_filepath = os.path.join(UPLOAD_DIR, converted_filename)
230
 
231
+
 
232
 
233
 
234
  #st.success(f"Image saved to {filepath}")