All Projects → qhgz2013 → Anime Face Detector

qhgz2013 / Anime Face Detector

Licence: mit
A Faster-RCNN based anime face detector implementation using tensorflow.

Programming Languages

python
139335 projects - #7 most used programming language

Projects that are alternatives of or similar to Anime Face Detector

Dockerface
Face detection using deep learning.
Stars: ✭ 173 (+47.86%)
Mutual labels:  face-detection, faster-rcnn
OpenCV-Anime-Face-Detector
Using OpenCV to detect and mark face and eye features in videos and images. Anime and manga faces are also detected.
Stars: ✭ 20 (-82.91%)
Mutual labels:  anime, face-detection
Paddledetection
Object Detection toolkit based on PaddlePaddle. It supports object detection, instance segmentation, multiple object tracking and real-time multi-person keypoint detection.
Stars: ✭ 5,799 (+4856.41%)
Mutual labels:  face-detection, faster-rcnn
PVANet-FACE
A face detection model based on PVANet
Stars: ✭ 49 (-58.12%)
Mutual labels:  faster-rcnn, face-detection
AnimeCV
Pretrained computer vision tools for illustrations.
Stars: ✭ 22 (-81.2%)
Mutual labels:  anime, face-detection
Face Tracking With Anime Characters
Hello! I have made a Python project where YURI from the game doki doki literature club accesses the webcam and stares directly into the players soul. Hope you enjoy!
Stars: ✭ 320 (+173.5%)
Mutual labels:  face-detection, anime
Sod
An Embedded Computer Vision & Machine Learning Library (CPU Optimized & IoT Capable)
Stars: ✭ 1,460 (+1147.86%)
Mutual labels:  face-detection
Desktop
Codebase for all the desktop versions (mac, linux & windows).
Stars: ✭ 113 (-3.42%)
Mutual labels:  anime
Tensorflow Mtcnn
C++ and python Inference only for MTCNN face detector on Tensorflow. Based on davidsandberg's facenet project:
Stars: ✭ 106 (-9.4%)
Mutual labels:  face-detection
Anime Chan
💡 A free RESTful API for anime quotes.
Stars: ✭ 106 (-9.4%)
Mutual labels:  anime
Tenginekit
TengineKit - Free, Fast, Easy, Real-Time Face Detection & Face Landmarks & Face Attributes & Hand Detection & Hand Landmarks & Body Detection & Body Landmarks & Iris Landmarks & Yolov5 SDK On Mobile.
Stars: ✭ 2,103 (+1697.44%)
Mutual labels:  face-detection
Hrnet Maskrcnn Benchmark
Object detection with multi-level representations generated from deep high-resolution representation learning (HRNetV2h).
Stars: ✭ 116 (-0.85%)
Mutual labels:  faster-rcnn
Deepface
Face analysis mainly based on Caffe. At this time, face analysis tasks like detection, alignment and recognition have been done.
Stars: ✭ 1,465 (+1152.14%)
Mutual labels:  face-detection
Anime
JavaScript animation engine
Stars: ✭ 41,064 (+34997.44%)
Mutual labels:  anime
Overmix
Automatic anime screenshot stitching in high quality
Stars: ✭ 114 (-2.56%)
Mutual labels:  anime
A Convolutional Neural Network Cascade For Face Detection
TensorFlow implementation of "A Convolutional Neural Network Cascade for Face Detection", CVPR 2015
Stars: ✭ 106 (-9.4%)
Mutual labels:  face-detection
Yolo V3 Iou
YOLO3 动漫人脸检测 (Based on keras and tensorflow) 2019-1-19
Stars: ✭ 116 (-0.85%)
Mutual labels:  anime
Awesome Face Detection
Compare with various detectors - s3fd, dlib, ocv, ocv-dnn, mtcnn-pytorch, face_recognition
Stars: ✭ 106 (-9.4%)
Mutual labels:  face-detection
Mobilenet Yolo
MobileNetV2-YoloV3-Nano: 0.5BFlops 3MB HUAWEI P40: 6ms/img, YoloFace-500k:0.1Bflops 420KB🔥🔥🔥
Stars: ✭ 1,566 (+1238.46%)
Mutual labels:  face-detection
Bmaskr Cnn
Boundary-preserving Mask R-CNN (ECCV 2020)
Stars: ✭ 116 (-0.85%)
Mutual labels:  faster-rcnn

Anime-Face-Detector

A Faster-RCNN based anime face detector.

This detector is trained on 6000 training samples and 641 testing samples, randomly selected from the dataset which is crawled from top 100 pixiv daily ranking.

Thanks to OpenCV based Anime face detector written by nagadomi, which helps labelling the data.

The original implementation of Faster-RCNN using Tensorflow can be found here

Dependencies

  • Python >= 3.6
  • tensorflow latest 1.x or 2.x
  • opencv-python (Will use other packages like pillow and scikit-image as backend in future version)
  • cython (optional, can be ignored with additional -nms-type PY_NMS argument)
  • Pre-trained ResNet101 model

Usage

  1. Clone this repository
    git clone https://github.com/qhgz2013/anime-face-detector.git
    
  2. Download the pre-trained model
    Google Drive: here
    Baidu Netdisk: here
  3. Unzip the model file into model directory
  4. Build the CPU NMS model (skip this step if use PY_NMS with argument: -nms-type PY_NMS)
    make clean
    make
    
    If using Windows Power Shell, type cmd /C make.bat to run build script.
  5. Run the demo as you want
    • Visualize the result (without output path):
      python main.py -i /path/to/image.jpg
      
    • Save results to a json file
      python main.py -i /path/to/image.jpg -o /path/to/output.json
      
      Format: {"image_path": [{"score": predicted_probability, "bbox": [min_x, min_y, max_x, max_y]}, ...], ...} Sample output file:
      {"/path/to/image.jpg": [{"score": 0.9999708, "bbox": [551.3375, 314.50253, 729.2599, 485.25674]}]}
      
    • Detecting a whole directory with recursion
      python main.py -i /path/to/dir -o /path/to/output.json
      
    • Customize threshold
      python main.py -i /path/to/image.jpg -nms 0.3 -conf 0.8
      
    • Customize model path
      python main.py -i /path/to/image.jpg -model /path/to/model.ckpt
      
    • Customize nms type (supports CPU_NMS and PY_NMS, not supports GPU_NMS because of the complicated build process for Windows platform)
      python main.py -i /path/to/image.jpg -nms-type PY_NMS
      
    • Crop detected images and store them in a folder (start output is an integer to start naming the cropped images, default is 0)
      python main.py -i /path/to/image/or/folder -crop-location /path/to/store/cropped/images -start-output 1
      
    • Crop detected images and resizes them
      python main.py -i /path/to/image/or/folder -crop-location /path/to/store/cropped/images -crop-height 224 -crop-width 224
      

Results

Mean AP for this model: 0.9086

Copyright info: 東方まとめ by 羽々斬

Copyright info: 【C94】桜と刀 by 幻像黒兎

Copyright info: アイドルマスター シンデレラガールズ by 我美蘭@1日目 東A-40a

About training

This model is directly trained by Faster-RCNN, with following argument:

python tools/trainval_net.py --weight data/imagenet_weights/res101.ckpt --imdb voc_2007_trainval --imdbval voc_2007_test --iters 60000 --cfg experiments/cfgs/res101.yml --net res101 --set ANCHOR_SCALES "[4,8,16,32]" ANCHOR_RATIOS "[1]" TRAIN.STEPSIZE "[50000]"

Dataset

We've uploaded the dataset to Google drive here, dataset structure is similar to VOC2007 (used in original Faster-RCNN implementation).

Citation and declaration

Feel free to cite this repo and dataset.
This work is not related to my research team and lab, just my personal interest.

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].