mirror of
https://github.com/vladmandic/automatic
synced 2026-09-18 16:54:33 +02:00
fix(grading): color grading type coercion, CLAHE, sharpness and tone scaling
- add __post_init__ to GradingParams to coerce Gradio int returns to float - apply CLAHE to L channel in Lab space instead of per-RGB channel - fix sharpness scaling (kornia factor 1.0=no change, map 0-based slider) - increase shadows/midtones/highlights gamma strength 2x for visible effect - reduce CLAHE clip slider range to 0-5 with finer 0.25 step
This commit is contained in:
@@ -205,7 +205,7 @@ def create_color_inputs(tab):
|
||||
grading_midtones = gr.Slider(minimum=-1.0, maximum=1.0, step=0.05, value=0, label='Midtones', elem_id=f"{tab}_grading_midtones")
|
||||
grading_highlights = gr.Slider(minimum=-1.0, maximum=1.0, step=0.05, value=0, label='Highlights', elem_id=f"{tab}_grading_highlights")
|
||||
with gr.Row(elem_id=f"{tab}_grading_clahe_row"):
|
||||
grading_clahe_clip = gr.Slider(minimum=0.0, maximum=40.0, step=1.0, value=0, label='CLAHE clip', elem_id=f"{tab}_grading_clahe_clip")
|
||||
grading_clahe_clip = gr.Slider(minimum=0.0, maximum=5.0, step=0.25, value=0, label='CLAHE clip', elem_id=f"{tab}_grading_clahe_clip")
|
||||
grading_clahe_grid = gr.Slider(minimum=2, maximum=16, step=1, value=8, label='CLAHE grid', elem_id=f"{tab}_grading_clahe_grid")
|
||||
with gr.Group():
|
||||
with gr.Row(elem_id=f"{tab}_grading_split_row"):
|
||||
|
||||
Reference in New Issue
Block a user