AMontiB commited on
Commit
61793df
Β·
1 Parent(s): 8e9829e
Files changed (3) hide show
  1. CFA.py +2 -1
  2. JPEG_Ghost.py +2 -1
  3. shadows.py +2 -1
CFA.py CHANGED
@@ -140,8 +140,9 @@ def build_demo():
140
  original_image_state = gr.State()
141
  box_coords_state = gr.State(value=(0, 0))
142
 
143
- gr.Markdown("# πŸ–ΌοΈ Image Patch Analyzer")
144
  gr.Markdown(
 
145
  "**Instructions:**\n"
146
  "1. **Upload** an image.\n"
147
  "2. **Click** anywhere on the image to move the 128x128 selection box.\n"
 
140
  original_image_state = gr.State()
141
  box_coords_state = gr.State(value=(0, 0))
142
 
143
+ gr.Markdown("# 🎨 Color Filter Array Analysis")
144
  gr.Markdown(
145
+ "Analyzes artifacts introduced during the camera's raw image processing. Inconsistencies in the **Color Filter Array (CFA)** interpolation pattern can reveal areas that have been spliced from another image or copy-pasted within the same image (copy-move).\n"
146
  "**Instructions:**\n"
147
  "1. **Upload** an image.\n"
148
  "2. **Click** anywhere on the image to move the 128x128 selection box.\n"
JPEG_Ghost.py CHANGED
@@ -99,8 +99,9 @@ def run_analysis(original_image: np.ndarray, box_coords: tuple, qf1: int, qf2: i
99
  def build_demo():
100
  # --- Build the Gradio Interface ---
101
  with gr.Blocks(theme=gr.themes.Soft()) as demo:
102
- gr.Markdown("# πŸ•΅οΈ JPEG Double Compression Analyzer")
103
  gr.Markdown(
 
104
  "**Instructions:**\n"
105
  "1. **Upload** an image.\n"
106
  "2. **Click** on the image to move the 256x256 selection box.\n"
 
99
  def build_demo():
100
  # --- Build the Gradio Interface ---
101
  with gr.Blocks(theme=gr.themes.Soft()) as demo:
102
+ gr.Markdown("# πŸ‘» JPEG Ghost Detection")
103
  gr.Markdown(
104
+ "Detects forgeries by identifying regions within an image that were compressed with different **JPEG Quality Factors (QF)**. When an area from a different JPEG image is spliced in, it often carries the 'ghost' of its original compression level, which this tool can reveal. NOTE: This tool AUTOMATICALLY SIMULATE THE JPEG GHOST BY RECOMPRESSING THE SELECTED AREA. \n"
105
  "**Instructions:**\n"
106
  "1. **Upload** an image.\n"
107
  "2. **Click** on the image to move the 256x256 selection box.\n"
shadows.py CHANGED
@@ -307,7 +307,8 @@ def reset_all(image, current_mode, current_points, y_lines, r_lines, y_pairs, r_
307
 
308
  def build_gradio_interface():
309
  with gr.Blocks() as demo:
310
- gr.Markdown("# Shadows and Lights Inconsistent Vanishing Points Analyzer πŸŒ•πŸŒ–πŸŒ—πŸŒ˜πŸŒ‘ \n \n A forensics tools that analyzes shadows vanishing points. Select two points (i.e. a corner and its corresponding shadow extremis)")
 
311
  with gr.Row():
312
  img_in = gr.Image(label="Upload image and then click to add points", type="numpy", interactive=True, height=800)
313
  with gr.Column():
 
307
 
308
  def build_gradio_interface():
309
  with gr.Blocks() as demo:
310
+ gr.Markdown("#πŸŒ•πŸŒ– Shadow Consistency Analysis πŸŒ—πŸŒ˜πŸŒ‘")
311
+ gr.Markdown("A utility for verifying geometric consistency of shadows in an image. By projecting vanishing points, it helps determine if all shadows correspond to a single, coherent light source. This method is based on principles of perspective and can be useful for analyzing both traditional manipulations and AI-generated images.")
312
  with gr.Row():
313
  img_in = gr.Image(label="Upload image and then click to add points", type="numpy", interactive=True, height=800)
314
  with gr.Column():