bumble-tech / private-detector Goto Github PK
View Code? Open in Web Editor NEWBumble's Private Detector - a pretrained model for detecting lewd images
License: Apache License 2.0
Bumble's Private Detector - a pretrained model for detecting lewd images
License: Apache License 2.0
Is it possible to install with Pip? I use venv and don't want to use conda.
Hi, I would like to inquire if you could provide a TensorFlow Lite private detector model with a dType of float32.
I've attempted to convert an existing saved_model.pb to .tflite for use on Android platform mobile phones. Android platform does not support Float16. Ultimately, I found a way to obtain a Float32 model, which is by retraining and setting the dType from Float16 to Float32 during the training process. However, this method does not seem to be orthodox, so I was wondering if you could provide a .tflite file with a dType of float32. Thank you.
I am AI newbie struggling to freeze the model but can not make it so far.
It would be very nice to put frozen model in the zipped model package as well.
Hello guys,
I hope this is the right place for that. TensorFlow Addons will be discontinued as of May 2024. I wondered if this will have any effect on this project? And if so what could those be?
Hey there, it would be awesome to see this model on the Hugging Face Model Hub. :)
I added a copy to my profile real quick to show you how to do it, and how easy it is to load once its up there...
import tensorflow as tf
from huggingface_hub import snapshot_download
model = tf.saved_model.load(snapshot_download(repo_id='nateraw/bumble-private-detector'))
I'd love to move this to an official org for bumble-tech
and have you folks fill out the model card. What do you think?
Hi, Is it possible to extend this to do multi-label classification to detect what type of nudity is shown? Or is it just not designed for that?
Thanks.
Would it make sense to include the Dockerfile for the vazhega/private-detector
image to https://github.com/bumble-tech/private-detector/tree/main/deployments/tensorflow-serving?
Dear Bumble tech,
I've been attempting to convert the private-detector's saved_model into a CoreML model. However, after the conversion, it seems unable to successfully identify NSFW images. I suspect there might be an issue during the conversion process. Could you guide me on how to correctly convert a saved_model.pb into a CoreML .mlPackage? Thanks a lot!
Here's my code:
import coremltools as ct
mlmodel_from_tf = ct.convert(model="/Path/To/private_detector/saved_model",
inputs=[ct.ImageType(shape=(1,480,480,3))],
source="tensorflow",
compute_precision=ct.precision.FLOAT32)
Results of testing the CoreML model:
from PIL import Image
img = Image.open('/Path/To/Desktop/dick3.png')
img = img.resize((480,480))
if img.mode != 'RGB':
img = img.convert('RGB')
out_dict = mlmodel_from_tf.predict({"model_input_images": img})
print(out_dict)
# {'Identity': array([[0.00386974, 0.9961302 ]], dtype=float32)}
# I believe the first element of the array represents the "confidence level that the content is NSFW." or I'm misunderstanding something?
Hello, I was wondering if there is a possibility to implement a functionality to serve this model straight away using any kind of containerized environment. Specifically, would be nice if the model would be able to accept some kind of standard (e.g base64) image representation instead of tensor representation, since that wouldn't require clients to implement the convertation on their end. Thank you!
I am writing to seek assistance with converting the model into the ONNX format. I have encountered some unresolved issues during the conversion process, and I am hoping to receive your guidance in order to successfully convert the model to the ONNX format.
Dear Bumble tech, I can see the code is under the Apache 2.0 license, what about the pre-trained model. You stand it is trained on 'private' data, what is the pre-trained model license ?
I tried to convert model to frozen graph, but couldn't find the output names need in freee_graph tool
freeze_graph --input_saved_model_dir=saved_model --output_node_names= --output_graph=frozen_graph.pb
thanks a lot!
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.