File size: 1,388 Bytes
e7f1d57
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
# ==============================================
# ImageScreenAI - Environment Configuration
# ==============================================

# Application
APP_NAME="ImageScreenAI"
VERSION="1.0.0"
DEBUG=False
LOG_LEVEL="INFO"

# Server Configuration
HOST="0.0.0.0"
PORT=7860
WORKERS=1

# File Processing
MAX_FILE_SIZE_MB=10
MAX_BATCH_SIZE=50
ALLOWED_EXTENSIONS=".jpg,.jpeg,.png,.webp"

# Detection Thresholds
REVIEW_THRESHOLD=0.65

# Metric Weights (must sum to 1.0)
GRADIENT_WEIGHT=0.30
FREQUENCY_WEIGHT=0.25
NOISE_WEIGHT=0.20
TEXTURE_WEIGHT=0.15
COLOR_WEIGHT=0.10

# Processing Configuration
ENABLE_CACHING=True
PROCESSING_TIMEOUT=30
PARALLEL_PROCESSING=False
MAX_WORKERS=1

# Paths (relative to project root)
BASE_DIR="."
UPLOAD_DIR="data/uploads"
REPORTS_DIR="data/reports"
CACHE_DIR="data/cache"
LOGS_DIR="logs"

# =========================================
# Hugging Face Spaces Specific
# =========================================
# These are automatically set by HF Spaces
# HF_SPACE_ID=""
# HF_SPACE_HOST=""

# =========================================
# Production Recommendations
# =========================================
# - Set DEBUG=False
# - Set LOG_LEVEL="WARNING" or "ERROR"
# - Adjust WORKERS based on available CPU cores
# - Enable PARALLEL_PROCESSING if CPU cores > 2
# - Set appropriate MAX_FILE_SIZE_MB for your use case
# =========================================