random2222 commited on
Commit
d10946b
·
verified ·
1 Parent(s): 1ca2a2d

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +4 -4
app.py CHANGED
@@ -424,7 +424,7 @@ def process_video_sketch(video_path, intensity=255, blur_ksize=21, sigma=0):
424
  def black_white_image(image, threshold_method, threshold_value):
425
  """Process image with black and white filter for Gradio"""
426
  # Log the usage of this feature
427
- logger.log_usage("black_white_image")
428
 
429
  if threshold_method != "manual":
430
  threshold_value = 0 # Not used for adaptive or Otsu
@@ -435,7 +435,7 @@ def black_white_image(image, threshold_method, threshold_value):
435
  def black_white_video(video, threshold_method, threshold_value):
436
  """Process video with black and white filter for Gradio"""
437
  # Log the usage of this feature
438
- logger.log_usage("black_white_video")
439
 
440
  if threshold_method != "manual":
441
  threshold_value = 0 # Not used for adaptive or Otsu
@@ -449,7 +449,7 @@ def black_white_video(video, threshold_method, threshold_value):
449
  def sketch_image(image, intensity, blur_ksize, sigma):
450
  """Process image with pencil sketch filter for Gradio"""
451
  # Log the usage of this feature
452
- logger.log_usage("sketch_image")
453
 
454
  result = process_image_sketch(image, intensity, blur_ksize, sigma)
455
  return Image.fromarray(result)
@@ -457,7 +457,7 @@ def sketch_image(image, intensity, blur_ksize, sigma):
457
  def sketch_video(video, intensity, blur_ksize, sigma):
458
  """Process video with pencil sketch filter for Gradio"""
459
  # Log the usage of this feature
460
- logger.log_usage("sketch_video")
461
 
462
  message, output_path = process_video_sketch(video, intensity, blur_ksize, sigma)
463
  if output_path:
 
424
  def black_white_image(image, threshold_method, threshold_value):
425
  """Process image with black and white filter for Gradio"""
426
  # Log the usage of this feature
427
+ logger.log_usage("black_white_image", "image")
428
 
429
  if threshold_method != "manual":
430
  threshold_value = 0 # Not used for adaptive or Otsu
 
435
  def black_white_video(video, threshold_method, threshold_value):
436
  """Process video with black and white filter for Gradio"""
437
  # Log the usage of this feature
438
+ logger.log_usage("black_white_video", "video")
439
 
440
  if threshold_method != "manual":
441
  threshold_value = 0 # Not used for adaptive or Otsu
 
449
  def sketch_image(image, intensity, blur_ksize, sigma):
450
  """Process image with pencil sketch filter for Gradio"""
451
  # Log the usage of this feature
452
+ logger.log_usage("sketch_image", "image")
453
 
454
  result = process_image_sketch(image, intensity, blur_ksize, sigma)
455
  return Image.fromarray(result)
 
457
  def sketch_video(video, intensity, blur_ksize, sigma):
458
  """Process video with pencil sketch filter for Gradio"""
459
  # Log the usage of this feature
460
+ logger.log_usage("sketch_video", "video")
461
 
462
  message, output_path = process_video_sketch(video, intensity, blur_ksize, sigma)
463
  if output_path: