PathoGen Model Weights
This repository contains the model weights for PathoGen, a diffusion-based histopathology inpainting model.
Model Components
π§ UNet Weights
- File:
diffusion_pytorch_model.bin(3.3GB) - Description: Main diffusion model weights for the UNet architecture
- Usage: Loaded automatically by the PathoGen pipeline
π― Attention Weights
- File:
attention.pt(190MB) - Description: Fine-tuned attention module weights for histopathology-specific features
- Usage: Custom attention processors for enhanced feature transfer
Usage
This model is designed to be used with the PathoGen Space:
- Space: https://huggingface.co/spaces/mkoohim/PathoGen
- Code: Available in the Space repository
Loading the Model
from diffusers import UNet2DConditionModel
import torch
# Load UNet
unet = UNet2DConditionModel.from_pretrained("./", subfolder="unet")
# Load attention weights
attention_weights = torch.load("attention.pt", map_location="cpu")
Model Details
- Architecture: Diffusion-based inpainting model
- Input Size: 512x512 pixels
- Inference Steps: 10 (optimized for speed)
- Framework: PyTorch + Diffusers
- Application: Histopathology image feature transfer
License
MIT License - See LICENSE file for details.
- Downloads last month
- 5