MuhammadQasimShabbir3's picture
fixed the model path for inference.
83180d6
Raw History Blame Contribute Delete
3.93 kB
{
"model_name": "HumanFace2ComicFaceGenerator",
"version": "6.0.0",
"description": "Progressive GAN for converting human faces to comic-style illustrations",
"author": "Your Name",
"license": "MIT",
"created_date": "2026-06-16",
"model": {
"generator": {
"type": "UNetEncoder-Decoder",
"input_nc": 3,
"output_nc": 3,
"ngf": 64,
"n_res_blocks": {
"64": 2,
"128": 4,
"256": 6
},
"dropout": 0.3,
"parameters": 35700000
},
"discriminator": {
"type": "PatchGAN",
"input_nc": 6,
"ndf": 64,
"n_layers": 3,
"parameters": 2770000
}
},
"training": {
"stages": [
{
"stage": 1,
"resolution": 64,
"epochs": 50,
"batch_size": 8,
"gradient_accumulation": 1,
"final_val_loss": 22.14,
"final_disc_loss": 0.53
},
{
"stage": 2,
"resolution": 128,
"epochs": 30,
"batch_size": 4,
"gradient_accumulation": 1,
"final_val_loss": 20.16,
"final_disc_loss": 0.45
},
{
"stage": 3,
"resolution": 256,
"epochs": 20,
"batch_size": 2,
"gradient_accumulation": 4,
"final_val_loss": 17.83,
"final_disc_loss": 0.46
}
],
"optimizer": {
"type": "Adam",
"learning_rate": 0.0002,
"beta1": 0.5,
"beta2": 0.999,
"weight_decay": 0.0001
},
"loss_weights": {
"adversarial": 1.0,
"l1": 10,
"perceptual": 5,
"feature_matching": 2,
"frequency": 1
},
"data_augmentation": {
"type": "DiffAugment",
"operations": ["color", "translation", "cutout"],
"random_flip": true
},
"regularization": {
"spectral_normalization": true,
"group_normalization": true,
"gradient_clipping": 1.0,
"ema_decay": 0.999,
"label_smoothing": {
"real_label": 0.9,
"fake_label": 0.1
}
}
},
"dataset": {
"name": "P2P-GAN Human2Comic Face Dataset",
"source": "https://www.kaggle.com/datasets/noob786/p2pgan-human2comic-face-paired-dataset",
"split": {
"train": 9900,
"validation": 100,
"test": 0
},
"image_size": [1024, 512],
"processed_size": [256, 256],
"description": "10,000 paired human and comic face images"
},
"evaluation": {
"metrics": {
"inception_score": 5.2,
"fid_score": 45.3,
"inference_time_ms": 50
},
"hardware": {
"training": "NVIDIA A100",
"training_hours": 100,
"inference_memory_vram_gb": 6,
"inference_memory_ram_gb": 8
}
},
"inference": {
"framework": "PyTorch",
"device": "cuda",
"precision": "float32",
"batch_size": 1,
"input_format": "PIL.Image or numpy.ndarray",
"output_format": "PIL.Image"
},
"deployment": {
"platforms": [
"HuggingFace Spaces",
"Local (GPU/CPU)",
"Docker",
"API"
],
"api_framework": "Gradio",
"api_version": "6.18.0",
"port": 7860,
"dependencies": [
"torch>=2.0.0",
"torchvision>=0.15.0",
"transformers>=4.30.0",
"gradio>=6.0.0",
"pillow>=9.0.0",
"numpy>=1.23.0"
]
},
"capabilities": {
"image_to_image": true,
"batch_processing": false,
"real_time_video": false,
"gpu_accelerated": true,
"quantized_variant": false,
"multi_resolution": true,
"style_transfer": true
},
"limitations": {
"requires_gpu": false,
"best_on_gpu": true,
"works_on_cpu": true,
"requires_faces": true,
"single_face_per_image": true,
"requires_frontality": "recommended",
"min_face_size_pixels": 64
},
"checkpoints": {
"generator_best": {
"file": "./model_weights/generator_best.pth",
"stage": 3,
"resolution": 256,
"size_mb": 246
}
}
}