import gradio as gr from nudenet import NudeDetector def process(input_img): detector = NudeDetector(model_path="640m.onnx", inference_resolution=640) converted = detector.censor(input_img) return converted iface = gr.Interface(fn=process,inputs="image", outputs="image") iface.launch()