Download README.md from Ruvadev/Raven: direct link, hf CLI and curl.
- Browser
- Download file 4.99 kB
-
https://huggingface.co/Ruvadev/Raven/resolve/main/README.md
- Command line
-
hf download hf://Ruvadev/Raven/README.md
-
curl -L -o README.md https://huggingface.co/Ruvadev/Raven/resolve/main/README.md
library_name: pytorch
pipeline_tag: image-classification
tags:
- computer-vision
- image-forensics
- ai-image-detection
- dinov2
- safetensors
Raven
Raven์ ์ค์ ์ฌ์ง๊ณผ AI ์์ฑ ์ด๋ฏธ์ง๋ฅผ ๊ตฌ๋ถํ๊ธฐ ์ํด ๋ง๋ ์ด๋ฏธ์ง ํฌ๋ ์ ๋ชจ๋ธ์ ๋๋ค.
์ต์ข
์ถ๋ ฅ์ REAL, AI, UNCERTAIN ๋ก ์ด 3๊ฐ์ง์ด๊ณ , AI ๋ฐ์ดํฐ๋ GPT Image 2 ๊ณ์ด์ ๊ธฐ์ค์ผ๋ก ํฉ๋๋ค.
ํ์ ๊ธฐ์ค์ ๋ค์๊ณผ ๊ฐ์ต๋๋ค.
REAL p(AI) <= 0.28
UNCERTAIN 0.28 < p(AI) < 0.72
AI p(AI) >= 0.72
์์์ฝ๋
import warnings
warnings.filterwarnings("ignore")
import sys
from pathlib import Path
HERE = Path(__file__).resolve().parent
sys.path.insert(0, str(HERE))
from raven.inference import infer_image
model = HERE / "model.safetensors"
image_extensions = {
".png",
".jpg",
".jpeg",
".webp",
".bmp",
}
images = sorted(
[
file for file in HERE.iterdir()
if file.is_file()
and file.suffix.lower() in image_extensions
],
key=lambda p: p.name.lower()
)
for image in images:
print(f"File: {image.name}")
result = infer_image(
str(model),
str(image),
)
print(f"Verdict: {result['verdict']}")
print(f"AI: {result['ai_probability'] * 100:.2f}%")
print(f"REAL: {result['real_probability'] * 100:.2f}%")
print()
Benchmark
Validation ๋ฐ์ดํฐ๋ ์ด 4,470์ฅ์ ๋๋ค.
- REAL: 3,003
- AI: 1,467
| Metric | Result | 95% CI |
|---|---|---|
| Accuracy | 98.635% | 98.251% - 98.936% |
| Balanced Accuracy | 98.566% | 98.159% - 98.935% |
| AUROC | 0.998255 | 0.997220 - 0.999083 |
| Balanced AP | 0.998472 | 0.997685 - 0.999135 |
| AI confirmed recall | 97.001% | 95.998% - 97.758% |
| REAL confirmed recall | 97.502% | 96.881% - 98.003% |
| AI to REAL error | 0.954% | 0.569% - 1.596% |
| REAL to AI error | 0.599% | 0.379% - 0.946% |
| Coverage | 98.054% | - |
| Selective accuracy | 99.207% | - |
| Uncertain | 1.946% | - |
| Balanced Brier | 0.011403 | - |
| Balanced ECE | 0.005572 | - |
Decisions
AI 1,467์ฅ:
AI 1,423
REAL 14
UNCERTAIN 30
REAL 3,003์ฅ:
REAL 2,928
AI 18
UNCERTAIN 57
REAL-only Test
๋ณ๋๋ก ๋ถ๋ฆฌ๋ REAL ์ด๋ฏธ์ง 2,986์ฅ์์๋ ํ๊ฐ๋ฅผ ํ์์ต๋๋ค.
| Metric | Result | 95% CI |
|---|---|---|
| Accuracy | 98.225% | 97.686% - 98.640% |
| REAL confirmed recall | 96.383% | 95.652% - 96.995% |
| REAL to AI error | 1.038% | 0.732% - 1.470% |
| Coverage | 97.421% | - |
| Selective accuracy | 98.934% | - |
| Uncertain | 2.579% | - |
์ค์ ํ์ ๊ฒฐ๊ณผ:
REAL 2,878
AI 31
UNCERTAIN 77
Lighting
Validation ๋ฐ์ดํฐ์ ๋ฐ๊ธฐ๋ณ ๊ฒฐ๊ณผ์ ๋๋ค.
| Group | N | Accuracy | AUROC | AI Recall | REAL Recall | Uncertain |
|---|---|---|---|---|---|---|
| dark | 299 | 99.331% | 0.999498 | 98.611% | 92.771% | 2.676% |
| dim | 1,137 | 98.769% | 0.999256 | 97.767% | 97.139% | 2.199% |
| extreme-dark | 28 | 96.429% | 1.000000 | 94.444% | 90.000% | 7.143% |
| normal | 3,006 | 98.536% | 0.997519 | 96.265% | 97.840% | 1.730% |
extreme-dark๋ ํ๋ณธ ์๊ฐ ์ ๊ธฐ ๋๋ฌธ์ ๋ค๋ฅธ ๊ตฌ๊ฐ๋ณด๋ค ์์น์ ๋ถํ์ค์ฑ์ด ํด ์ ์์ต๋๋ค.
Limitations
ํ์ฌ AI ํ์ต ๋ฐ์ดํฐ๋ GPT Image 2๋ฅผ ์ค์ฌ์ผ๋ก ๊ตฌ์ฑ๋์ด ์์ต๋๋ค.
๋ฐ๋ผ์ ์ benchmark๋ GPT Image 2 ๊ณ์ด๊ณผ ํ์ฌ REAL ๋ฐ์ดํฐ ๋ถํฌ์์์ ์ฑ๋ฅ์ ๋ํ๋ ๋๋ค.
๋ค์๊ณผ ๊ฐ์ ๊ฒฝ์ฐ ๋์ผํ ์ฑ๋ฅ์ ๋ณด์ฅํ์ง ์์ต๋๋ค.
- ํ์ต์ ํฌํจ๋์ง ์์ AI ์์ฑ ๋ชจ๋ธ
- ๊ฐํ JPEG ์ฌ์์ถ
- ์คํฌ๋ฆฐ์ท
- ์ ์ค์ผ์ผ ๋ฐ ๋ ธ์ด์ฆ ์ ๊ฑฐ
- ๊ณผ๋ํ ์๋ณด์ ๋๋ ํ์ฒ๋ฆฌ
- ์ด๋ฏธ์ง ์ผ๋ถ๋ง ํฉ์ฑ๋ ๊ฒฝ์ฐ
- ๋งค์ฐ ์ด๋์ด ์ด๋ฏธ์ง
ํนํ Midjourney, FLUX, Stable Diffusion ๋ฑ ๋ค๋ฅธ ์์ฑ๊ธฐ์์์ ์ฑ๋ฅ์ ๋ณ๋๋ก ๊ฒ์ฆ๋์ด์ผ ํฉ๋๋ค.
Raven์ ์ถ๋ ฅ์ ์ด๋ฏธ์ง ์ถ์ฒ์ ๋ํ ํ๋ฅ ๊ธฐ๋ฐ ํฌ๋ ์ ํ๋จ์ด๋ฉฐ, ์ด๋ฏธ์ง๊ฐ AI๋ก ์์ฑ๋์์์ ์ฆ๋ช ํ๋ ์ ๋์ ์ธ ์ฆ๊ฑฐ๋ก ์ฌ์ฉํด์๋ ์ ๋ฉ๋๋ค.