File size: 7,499 Bytes
2422df7 b2bf333 e9f1952 b2bf333 b51fd25 b2bf333 0fa033b 417b9bc 760eb86 a79fed5 f71c34e d44b03b b59cfac 2ccbd6e f9f0da7 2ccbd6e 1990877 b59cfac 7fafc9a b59cfac 2fa0bdf b59cfac 7fafc9a b59cfac 2fa0bdf b59cfac 20e4426 b59cfac 20e4426 b59cfac 7fafc9a b59cfac 20e4426 b59cfac 7fafc9a b59cfac 760eb86 b59cfac 760eb86 b59cfac 760eb86 b59cfac 760eb86 b59cfac 760eb86 b59cfac 760eb86 b59cfac 760eb86 b59cfac 760eb86 b59cfac 7fafc9a b59cfac ca3b032 48e7e2e b59cfac 760eb86 7883cdc 93737c3 39c7f5a c6fb266 39c7f5a 7883cdc 760eb86 b59cfac 44c4f92 |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 |
---
license: apache-2.0
language:
- en
metrics:
- accuracy
pipeline_tag: image-classification
tags:
- image-classification
- animation
- gender classification
- computer_vision
- dof_studio
- nathmath
---
### animeGender-dvgg-0.7
- A cutting edge model for anime character gender classification.
- Update: Our new models ARE ALREADY RELEASE, with supreme performance, a brand new technique called transgressivability, and a wide range of model choices.
To get the latest release, you can follow us and like this repo.
- πππππ
Updated Models: https://huggingface.co/DOFOFFICIAL/animeGender-dvgg-0.8.
### Description
- Our proposal model, animeGender-dvgg-0.7, which is a fine-tuned binary classification model created by DOF-Studio (2023) and based on the pre-trained model vgg-16, aims to identify the gender, or sex of a particular animation character (particularly designed for Japanese-style 2D anime characters). It is trained by DOF-Studio in July, 2023, on an organizational private data set that is manually collected and tagged by our staff. Although this model has shown an unprecedentedly successful and charming result of our test and verification data set, please note that this model is still not the final version of our character-gender identification model series, but only a phased result (Version 0.7) of our open-source project, which means upgraded versions will be soon released by our team in the near future, and we are confident to tell that as we have improved the network structure, so that there is going to be a magnificent amelioration in the up-coming ones. Thank you for all of your appreciation and support for our work and models.
### Technical Details
- Modification: This model, animeGender-dvgg-0.7, uses all weights from the convolutional neural network of the original vgg-16 model released by an Oxford team, but has changed the network structure of the last sequantials, say, the dense layers, which means we have modified it into a binary classification model with two nodes (activated by a softmax layer) output the possibility of each gender, namely female, and male. Note that although the overall network structure, particularly the convolutional neural layers have been left untrained, in the future, we have planned to deeply modify this base model, vgg16, to achieve a higher score and precision in this classification task.
- Input: While the original model vgg-16 has been designed with an input with 224 * 224 in terms of resolution, and 3 dementions in RGB colorspace, in our model animeGender-dvgg-0.7, we aim to only use 64 * 64 with RGB colorspace only, as the classification task is not too tough. Please note when feeding a picture into the model, please ensure that the input illustration only consists of the head and face of the character you want to identify, in order to make the result from the model most precise and reliable. Moreover, we have designed some Python functions in our open source codes to help you resize, crop, and transform your pictures into 64 * 64 RGB ones, and more information is available in the file folder.
- Output: This model, animeGender-dvgg-0.7, has an original output with a one-dim tensor, which length is 2, respectively shows the possibilities of each result of your input, namely female and male. In our open source usage example, see in the file folder, we have conveniently transformed the raw output into a readable result, for example, "male", with a numerical number showing the possibility, or the confidence. Note that our model does not have the background knowledge of a certain character, or the context of an animation, so some gender-neutral characters may still be misclassified, or correctly matched but with a confidence that is around 0.5.
- Checkpoint: We have provided the final and proposal model with the name "animeGender-dvgg-0.7", however, to satisfy some further requirements, for example, research, we have provided checkpoints on process, while they have been proved to have an inferior capability compared to the proposed model. More models available, please see the file folder.
### Results and Rankings
- Based on the training data and testing data, the proposal model has achieved a result shown below:
- name = animeGender-dvgg-0.7
- epoch = 50
- trainSet = 20k
- trainLoss = 0.0019
- trainAcc = 0.9640
- testSet = 1.4k
- testLoss = 0.0024
- testAcc = 0.9267
### Examples
- Here are some sample-exteral tests that are conducted by our staff with the corresponding results shown below:
[Pic 0]
![Pic 0](https://cdn-uploads.huggingface.co/production/uploads/64a59126f988662d058c4fb7/_yHVFm91B7-fCNBkuKFNf.png)
[Pic 0] This is female with a confidence of 0.991.
[Pic 1]
![Pic 1](https://cdn-uploads.huggingface.co/production/uploads/64a59126f988662d058c4fb7/0phmkYFC1nfMHsZ7__4NG.png)
[Pic 1] This is female with a confidence of 0.994.
[Pic 2]
![Pic 2](https://cdn-uploads.huggingface.co/production/uploads/64a59126f988662d058c4fb7/2XWirU8RFNrg3HP3-kFuP.png)
[Pic 2] This is male with a confidence of 0.604.
[Pic 3]
![Pic 3](https://cdn-uploads.huggingface.co/production/uploads/64a59126f988662d058c4fb7/nqYI8accIVUsFLjFll_Hs.png)
[Pic 3] This is male with a confidence of 0.671.
[Pic 4]
![Pic 4](https://cdn-uploads.huggingface.co/production/uploads/64a59126f988662d058c4fb7/szj1Io23S05aH4vXHo6PK.png)
[Pic 4] This is female with a confidence of 0.886.
[Pic 5]
![Pic 5](https://cdn-uploads.huggingface.co/production/uploads/64a59126f988662d058c4fb7/7OSp0nDHbrqgIoyKF3od5.png)
[Pic 5] This is female with a confidence of 0.998.
[Pic 6]
![Pic 6](https://cdn-uploads.huggingface.co/production/uploads/64a59126f988662d058c4fb7/4LmkTtoi6_c-kP5mgpnAC.png)
[Pic 6] This is female with a confidence of 1.0.
[Pic 7]
![Pic 7](https://cdn-uploads.huggingface.co/production/uploads/64a59126f988662d058c4fb7/77Bxn_vibwGvxser0BsYg.png)
[Pic 7] This is female with a confidence of 0.997.
### Usage
- We have uploaded the usage with Python in the file folder, and please note you should download them and run locally using either your CPU or with CUDA.
- Note that only the provided codes can be regarded as the only recommended approach to use this model, while other ways including those are automatically shown on this website are not guaranteed to be valid and user-friendly.
- Note that ".bin" or ".pth" models should be used with the pre-defined function modelload() in the provided codes, but ".safetensors" models (baked with built-in configs) can otherwise be simply loaded with the function torch.load().
- Only does the proposal model named "animeGender-dvgg-0.7" has been avaiable in different formats, for example, ".bin", ".safetensors", ".onnx", and ".pb", while the phased ones have not been converted yet.
### Notifications
- We confidently claim that all data we trained on were from real-human illustrations, but our model is also suitable for generative graphs, for example, those generated from stable diffusion, with a relatively high accuracy correspondingly.
- We confidently claim that all model related files excluding this README.md file will never be changed ever since the initial release, so please follow and like us to chase an updated version.
- New improved models have already been officially released by our team, and please refer links shown below:
- Version 0.8: https://huggingface.co/DOFOFFICIAL/animeGender-dvgg-0.8.
Yours,
Team DOF Studio, July 6th, 2023. |