Package for calculating Frechet CLIP Distance (FCD) using PyTorch
Project description
FCD_Score
Fréchet CLIP Distance Score: Fréchet CLIP Distance Score calculate Fréchet Distance based on features from CLIP image encoder.
FCD measure similarity between generated images and the dataset.
Installation
Install from pip:
pip install pytorch-fcd
Requirements:
ftfy
regex
numpy
pillow
scipy
torch>=1.7.1
torchvision>=0.8.2
clip
Usage
calculate and save statistics for datasest:
pytorch-fcd --model-name "ViT-B/32" --savepath path_to_image_dataset path_to_save_file
calculate FCD score for image dataset and generated image dataset:
pytorch-fcd --model-name "ViT-B/32" --paths path_to_image_dataset path_to_generated_image_dataset
Citing
If you use this repository in your research, consider citing it using the following Bibtex entry:
@misc{ShanYang2023FCD,
author={Shan Yang},
title={{pytorch-fcd: FCD Score for PyTorch}},
month={Nov},
year={2023},
note={Version 1.0.0.dev1},
howpublished={\url{https://github.com/syang-lab/FCD_Score}}
}
License
This implementation is licensed under the Apache License 2.0.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distributions
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file pytorch_fcd-1.0.1.dev1-py3-none-any.whl.
File metadata
- Download URL: pytorch_fcd-1.0.1.dev1-py3-none-any.whl
- Upload date:
- Size: 9.1 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.2 CPython/3.8.18
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
3c0b98e3347fc51b4f7845a230fa793009e6fe12c0b7a6a4079ea41423d5473f
|
|
| MD5 |
e40996f533676a776ac500c268de63f3
|
|
| BLAKE2b-256 |
abc4378d04b77c0fc03e4f9285f6a1fe3a521c4950f7971626501e064d146034
|