Instructions to use Modotte/AIRealNet with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use Modotte/AIRealNet with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("image-classification", model="Modotte/AIRealNet") pipe("https://huggingface.co/datasets/huggingface/documentation-images/resolve/main/hub/parrots.png")# pip install -U transformers accelerate # Load model directly from transformers import AutoImageProcessor, AutoModelForImageClassification processor = AutoImageProcessor.from_pretrained("Modotte/AIRealNet") model = AutoModelForImageClassification.from_pretrained("Modotte/AIRealNet", device_map="auto") - Inference
- Notebooks
- Google Colab
- Kaggle
Download config.json from Modotte/AIRealNet: direct link, hf CLI and curl.
- Browser
- Download file 576 Bytes
-
https://huggingface.co/Modotte/AIRealNet/resolve/main/config.json
- Command line
-
hf download hf://Modotte/AIRealNet/config.json
-
curl -L -o config.json https://huggingface.co/Modotte/AIRealNet/resolve/main/config.json
576 Bytes
| { | |
| "_num_labels": 2, | |
| "architectures": [ | |
| "Swinv2ForImageClassification" | |
| ], | |
| "depths": [2, 2, 18, 2], | |
| "drop_path_rate": 0.1, | |
| "embed_dim": 192, | |
| "encoder_stride": 32, | |
| "hidden_size": 1536, | |
| "id2label": { | |
| "0": "artificial", | |
| "1": "real" | |
| }, | |
| "image_size": 256, | |
| "label2id": { | |
| "artificial": 0, | |
| "real": 1 | |
| }, | |
| "mlp_ratio": 4.0, | |
| "model_type": "swinv2", | |
| "num_channels": 3, | |
| "num_heads": [6, 12, 24, 48], | |
| "out_features": ["stage4"], | |
| "patch_size": 4, | |
| "path_norm": true, | |
| "pretrained_window_sizes": [12, 12, 12, 6], | |
| "window_size": 16 | |
| } | |