Severian commited on
Commit
792d64a
·
verified ·
1 Parent(s): 5d37781

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +7 -3
app.py CHANGED
@@ -45,7 +45,12 @@ print("Initializing the Enhanced CMT Holography Explorer...")
45
  # ---------------------------------------------------------------
46
  # Data setup
47
  # ---------------------------------------------------------------
48
- BASE_DIR = os.path.abspath(os.getcwd())
 
 
 
 
 
49
  DATA_DIR = os.path.join(BASE_DIR, "data")
50
  DOG_DIR = os.path.join(DATA_DIR, "dog")
51
  HUMAN_DIR = os.path.join(DATA_DIR, "human")
@@ -1418,5 +1423,4 @@ with gr.Blocks(theme='Nymbo/Alyx_Theme') as demo:
1418
  print("✅ CMT Holographic Visualization Suite Ready!")
1419
 
1420
  if __name__ == "__main__":
1421
- pass
1422
-
 
45
  # ---------------------------------------------------------------
46
  # Data setup
47
  # ---------------------------------------------------------------
48
+ # If running inside the proxy, PRIVATE_APP_ROOT will be set.
49
+ # Otherwise, fall back to the current working directory for standalone execution.
50
+ _app_root = os.getenv("PRIVATE_APP_ROOT", os.path.abspath(os.getcwd()))
51
+ print(f"✅ Application Root detected as: {_app_root}")
52
+
53
+ BASE_DIR = _app_root
54
  DATA_DIR = os.path.join(BASE_DIR, "data")
55
  DOG_DIR = os.path.join(DATA_DIR, "dog")
56
  HUMAN_DIR = os.path.join(DATA_DIR, "human")
 
1423
  print("✅ CMT Holographic Visualization Suite Ready!")
1424
 
1425
  if __name__ == "__main__":
1426
+ demo.launch()