Spaces:
Sleeping
Sleeping
A newer version of the Gradio SDK is available:
6.2.0
BytePlus Image Generation Studio - Directory Access Guide
β Problem Resolved!
The view_session/, Generated/, and static/ folders are now accessible. Here's what was done:
π§ What Was Fixed
- Permission Issues: The
.cachedirectory had restrictive permissions (700) that prevented access - Missing Directories: The folders weren't created until the app actually generates images
- Path Confusion: The folders exist inside the hidden
.cachedirectory
π Directory Structure
/Users/data/SGS-1/
βββ .cache/ # Hidden cache (downloaded Hugging Face space)
β βββ Generated/ # Original generated images folder
β βββ static/ # Original static files folder
β βββ view_session/ # Original session viewer folder
β βββ app.py # Downloaded BytePlus app
βββ Generated -> .cache/Generated # Symbolic link for easy access
βββ static -> .cache/static # Symbolic link for easy access
βββ view_session -> .cache/view_session # Symbolic link for easy access
βββ run_app.py # Helper script to run the app
βββ check_directories.py # Script to check directory status
π How to Use
Option 1: Use the Helper Script (Recommended)
# Run the app with automatic setup
python run_app.py
# Or just setup directories without running
python run_app.py --setup-only
Option 2: Manual Commands
# Check directory status
python check_directories.py
# Run the downloaded app directly
cd .cache && python app.py
π Directory Functions
Generated/: Stores generated images organized by session (e.g.,session_20240924_143052/)static/: Contains static files served by the web interface (ZIP downloads, etc.)view_session/: Used by the web interface for session viewing functionality
π Web Interface URLs
When the app is running, you can access:
- Main interface:
http://localhost:7860(or the port shown in terminal) - Session viewer:
http://localhost:7860/view_session/{timestamp} - Static files:
http://localhost:7860/static/filename.zip
π οΈ Troubleshooting
If you still can't access the directories:
Check permissions:
ls -la .cache # Should show: drwxr-xr-x (755 permissions)Recreate symbolic links:
python run_app.py --setup-onlyCheck directory status:
python check_directories.py
π Notes
- The directories will be empty until you actually generate images using the app
- Session folders are created with timestamps like
session_20240924_143052 - ZIP files for downloads are automatically created in the
static/folder - The
view_session/functionality allows viewing generated images via web browser
π Related Files
app.py- Original loader script.cache/app.py- Downloaded BytePlus Image Generation Studiorun_app.py- Helper script for running the appcheck_directories.py- Directory status checker
The directories are now fully accessible and the app is ready to use! π