| Age | Commit message (Collapse) | Author |
|
Delete hyperstack-vm-photo.toml, photo-enhance.rb, photo-enhance-review.md,
smart_photo_node.py, workflows/photo-enhance.json (and empty workflows/ dir),
and __pycache__/smart_photo_node.cpython-314.pyc (and empty __pycache__/ dir).
No .hyperstack-vm-photo-state.json* state files were present.
ComfyUI references in lib/hyperstack/*.rb intentionally left for task T2.
|
|
realesr-general-x4v3.pth was referenced but only RealESRGAN_x4plus.pth is
pre-installed via the TOML config. Use the available model to avoid workflow
errors on first run. Both are 4x ESRGAN models; x4plus is the standard photo
quality option.
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
|
|
grading
Addresses all five priority improvements from photo-enhance-review.md:
1. Conditional ESRGAN (ConditionalESRGANBlend node): portrait and night
scenes skip Real-ESRGAN entirely; indoor/golden_hour use a reduced
blend (0.25–0.60); landscape/beach keep full strength. Confidence-
weighted ratios from CLIP scores soften hard scene-boundary transitions.
2. Blended CLIP scene profiles: CLIPSceneDetect now outputs top-3 scene
scores as a normalised JSON string. AdaptivePhotoGrade blends the
matching grading profiles weighted by confidence instead of hard-
switching on the argmax label — a 55/35/10 landscape/golden_hour/overcast
split produces a weighted average of those three profiles.
3. Conservative depth defaults: DepthSelectiveSharpen background_blur
changed from 0.50 to 0.0 (disabled by default). Foreground sharpening
is kept; background blur can be re-enabled explicitly per shot.
4. EXIF/ICC preservation: copy_exif() in photo-enhance.rb uses exiftool
to restore capture time, camera/lens info, GPS, and ICC profile from
the source file onto the enhanced JPEG after ComfyUI strips metadata.
Embedded thumbnail/preview are excluded to avoid showing the old image.
5. Provenance logging: prompt_id is now passed into the metadata markdown
report. WritePhotoMetadata emits scene_scores and esrgan_mode into the
JSON sidecar. The markdown report now shows top-3 scene confidences,
ESRGAN mode, and ComfyUI prompt ID for reproducibility.
Workflow restructured: CLIPSceneDetect now runs on the original image
(before ESRGAN) so scene scores are available to gate the upscaler.
ConditionalESRGANBlend (node 16) inserted between ESRGAN downscale and
CodeFormer. All downstream nodes receive scene_scores via node 11 outputs.
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
|
|
Complete overhaul of the ComfyUI photo enhancement stack:
Pipeline (workflows/photo-enhance.json):
- Real-ESRGAN realesr-general-x4v3: 4x upscale at full 4K input (no pre-downscale,
preserves all original detail before AI sees it), output scaled back to 4K
- CodeFormer fidelity=0.7: GPU neural face detection + restoration
- CLIP ViT-B/32: zero-shot scene classification (portrait/landscape/night/
indoor/golden_hour/overcast/beach/street)
- AdaptivePhotoGrade: scene-tuned exposure/contrast/saturation/detail using
guided-filter clarity enhancement; simple linear exposure shift (replaces
Reinhard tonemapping which was darkening already-exposed Fuji photos)
- SkyEnhance: HSV sky mask (blue sky + clouds + sunset) with spatial prior,
graduated exposure and saturation boost for sky regions
- DepthSelectiveSharpen: Depth Anything V2 Small depth map → foreground
sharpening, background softening
- WritePhotoMetadata: writes per-photo JSON to ComfyUI output dir
smart_photo_node.py: implements all 5 new ComfyUI custom nodes
photo-enhance.rb:
- Downloads per-photo metadata JSON from ComfyUI and renders it as a
human-readable _e.md report alongside each enhanced JPEG
- inject_input now also patches WritePhotoMetadata with prefix + source filename
- Updated pipeline description in header comments
photo-compare.rb: GTK4 side-by-side comparison GUI — show original vs
enhanced, keyboard shortcuts O/E to move preferred version to outdir,
Space to skip, auto-rescans as new photos arrive
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
|
|
- Preprocess to 2K before SUPIR (ImageScaleBy 0.5) — reduces tiles from
96 to 6, VAE encode drops from 190s to 13s
- SUPIR: 8 steps (vs 15), fp8_unet=true, larger sampler tiles (512/256)
- Real-ESRGAN 4x upscale back to 4K after SUPIR (node 4-6)
- Measured ~5 min/photo on L40 vs 25+ min/photo at 4K with 15 steps
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
|
|
- workflows/photo-enhance.json: replace Real-ESRGAN-only pipeline with
SUPIR_Upscale (SUPIR-v0Q + SDXL base backbone). Parameters:
20 steps, scale_by=1.0 (original resolution), Wavelet colour fix,
tiled VAE + tiled sampling for L40 VRAM headroom.
- photo-enhance.rb: add ImageMagick colour corrections after download:
S-curve contrast (-sigmoidal-contrast 3,50%), +20% saturation
(-modulate 100,120,100), micro-contrast sharpening (-unsharp).
These stack on top of SUPIR's internal Wavelet colour fix.
- hyperstack.rb: update comfyui_install_script to install ComfyUI-SUPIR
custom node and download both SUPIR-v0Q + sd_xl_base_1.0 on provision.
- hyperstack.rb: extend status_config_loaders to auto-discover
hyperstack-vm-photo.toml so --watch shows the photo VM.
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
|
|
- hyperstack-vm-photo.toml: L40 GPU VM config (192.168.3.4, ~$1/hr)
with [comfyui] section for port, model dirs, and pre-downloaded weights
- hyperstack.rb: full ComfyUI provisioning support alongside vLLM/Ollama —
config accessors, comfyui_install_script (git clone + venv + systemd),
RemoteProvisioner#install_comfyui, Manager#create integration, UFW rules,
status/service_mode_summary updates, --comfyui/--no-comfyui CLI flags
- photo-enhance.rb: standalone client — uploads photos, submits ComfyUI
workflow, polls for output, downloads PNG, converts to JPEG at quality 92
so file sizes match originals; --watch mode; processed-file manifest
- workflows/photo-enhance.json: Real-ESRGAN x4plus enhance-in-place workflow
(upscale 4x for enhancement, ImageScaleBy 0.25 back to original resolution)
- README.md: Photo enhancement section with quickstart, config reference,
workflow customisation notes, and performance table
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
|