H1merka commited on
Commit
40b8ed9
·
verified ·
1 Parent(s): 855e19d

Upload 2 files

Browse files

docs: update README and config.json

Files changed (2) hide show
  1. README.md +12 -15
  2. config.json +12 -27
README.md CHANGED
@@ -23,10 +23,10 @@ model-index:
23
  name: AI-Generated Image Detection
24
  metrics:
25
  - type: accuracy
26
- value: 0.656
27
  name: Validation Accuracy
28
  - type: loss
29
- value: 0.308
30
  name: Validation Loss
31
  ---
32
 
@@ -84,24 +84,23 @@ The model uses a **Full Mode** architecture with three complementary analysis br
84
 
85
  | Parameter | Value |
86
  |-----------|-------|
87
- | Epochs | 3 |
88
- | Batch Size | 8 |
89
  | Image Size | 256×256 |
90
- | Learning Rate | 1e-4 (with warmup) |
91
  | Optimizer | AdamW |
92
- | Scheduler | Cosine Annealing |
93
- | Mixed Precision | Enabled (AMP) |
94
- | Hardware | NVIDIA RTX 3050 Ti (4GB VRAM) |
95
 
96
  ### Training Results
97
 
98
  | Epoch | Train Loss | Val Loss | Val Accuracy |
99
  |-------|------------|----------|--------------|
100
- | 0 | 0.4115 | 0.3262 | 61.46% |
101
- | 1 | 0.3707 | 0.3099 | 65.09% |
102
- | 2 | 0.3506 | **0.3079** | **65.55%** |
103
-
104
- **Note**: This is an early checkpoint after 3 epochs of training. The model is still learning and accuracy will improve with more training epochs (recommended: 30-50 epochs for production use).
105
 
106
  ## Usage
107
 
@@ -234,7 +233,6 @@ The checkpoint file (`best_model.pt`) contains:
234
  | `model_state_dict` | Model weights |
235
  | `optimizer_state_dict` | Optimizer state (for resume training) |
236
  | `scheduler_state_dict` | LR scheduler state |
237
- | `scaler_state_dict` | AMP GradScaler state |
238
  | `epoch` | Training epoch number |
239
  | `global_step` | Global training step |
240
  | `best_val_loss` | Best validation loss achieved |
@@ -243,7 +241,6 @@ The checkpoint file (`best_model.pt`) contains:
243
 
244
  ## Limitations
245
 
246
- - **Early Training Stage**: This checkpoint is from early training (3 epochs). For production use, train for 30-50+ epochs.
247
  - **Dataset Bias**: Performance may vary on images from generators not represented in the training set.
248
  - **Resolution Dependency**: Best results at 256×256. Other resolutions are automatically resized.
249
  - **Adversarial Robustness**: Not specifically hardened against adversarial attacks.
 
23
  name: AI-Generated Image Detection
24
  metrics:
25
  - type: accuracy
26
+ value: 0.710
27
  name: Validation Accuracy
28
  - type: loss
29
+ value: 0.216
30
  name: Validation Loss
31
  ---
32
 
 
84
 
85
  | Parameter | Value |
86
  |-----------|-------|
87
+ | Epochs | 15 |
88
+ | Batch Size | 16 |
89
  | Image Size | 256×256 |
90
+ | Learning Rate | 2e-6 |
91
  | Optimizer | AdamW |
92
+ | Scheduler | OneCycleLR |
93
+ | Mixed Precision | Disabled |
94
+ | Hardware | NVIDIA Tesla T4 (16GB VRAM) |
95
 
96
  ### Training Results
97
 
98
  | Epoch | Train Loss | Val Loss | Val Accuracy |
99
  |-------|------------|----------|--------------|
100
+ | 10 | 0.2555 | 0.2238 | 68.48% |
101
+ | 11 | 0.2504 | 0.2207 | 69.57% |
102
+ | 12 | 0.2501 | 0.2194 | 69.90% |
103
+ | 15 | 0.2468 | **0.2163** | **71.03%** |
 
104
 
105
  ## Usage
106
 
 
233
  | `model_state_dict` | Model weights |
234
  | `optimizer_state_dict` | Optimizer state (for resume training) |
235
  | `scheduler_state_dict` | LR scheduler state |
 
236
  | `epoch` | Training epoch number |
237
  | `global_step` | Global training step |
238
  | `best_val_loss` | Best validation loss achieved |
 
241
 
242
  ## Limitations
243
 
 
244
  - **Dataset Bias**: Performance may vary on images from generators not represented in the training set.
245
  - **Resolution Dependency**: Best results at 256×256. Other resolutions are automatically resized.
246
  - **Adversarial Robustness**: Not specifically hardened against adversarial attacks.
config.json CHANGED
@@ -12,13 +12,15 @@
12
  "fast_mode": false
13
  },
14
  "training_config": {
15
- "epochs_trained": 3,
16
- "batch_size": 8,
17
- "learning_rate": 0.0001,
18
  "optimizer": "adamw",
19
- "scheduler": "cosine",
20
- "mixed_precision": true,
21
- "warmup_epochs": 5
 
 
22
  },
23
  "dataset_info": {
24
  "train_samples": 128776,
@@ -29,9 +31,9 @@
29
  "fake_ratio": 0.542
30
  },
31
  "metrics": {
32
- "best_val_loss": 0.3079,
33
- "best_val_accuracy": 0.6555,
34
- "final_train_loss": 0.3506
35
  },
36
  "input_spec": {
37
  "type": "image",
@@ -51,22 +53,5 @@
51
  "1.0": "real/natural image",
52
  "0.0": "fake/generated image"
53
  }
54
- },
55
- "checkpoint_info": {
56
- "format": "pytorch",
57
- "keys": [
58
- "model_state_dict",
59
- "optimizer_state_dict",
60
- "scheduler_state_dict",
61
- "scaler_state_dict",
62
- "epoch",
63
- "global_step",
64
- "best_val_loss",
65
- "train_history",
66
- "val_history"
67
- ]
68
- },
69
- "version": "0.1.0",
70
- "library_name": "tigas",
71
- "github_repo": "https://github.com/H1merka/TIGAS"
72
  }
 
12
  "fast_mode": false
13
  },
14
  "training_config": {
15
+ "epochs_trained": 15,
16
+ "batch_size": 16,
17
+ "learning_rate": 0.000002,
18
  "optimizer": "adamw",
19
+ "scheduler": "onecycle",
20
+ "mixed_precision": false,
21
+ "regression_weight": 1.0,
22
+ "classification_weight": 0.2,
23
+ "ranking_weight": 0.1
24
  },
25
  "dataset_info": {
26
  "train_samples": 128776,
 
31
  "fake_ratio": 0.542
32
  },
33
  "metrics": {
34
+ "best_val_loss": 0.2163,
35
+ "best_val_accuracy": 0.7103,
36
+ "final_train_loss": 0.2468
37
  },
38
  "input_spec": {
39
  "type": "image",
 
53
  "1.0": "real/natural image",
54
  "0.0": "fake/generated image"
55
  }
56
+ }
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
57
  }