# mseitzer/pytorch-fid

Compute FID scores with PyTorch.

Repository: https://github.com/mseitzer/pytorch-fid
Canonical: https://ross.abutalabs.com/products/pytorch-fid
Language: Python
License: Apache-2.0
License Family: permissive
Topics: pytorch, gan, generative-adversarial-network, fid-score, deep-learning, frechet-distance, inception-score, fid
Last push: 2024-07-03T06:40:02+00:00

## Health v2 (maintenance only)
Score: 23/100 (v2, computed 2026-09-02T17:46:02.011165+00:00)
- activity 0, release rhythm 8, longevity 100
- inputs: {"age_days": 3126, "days_push": 791, "days_rel": null, "gap_med": null, "n_releases_24m": 0}
- flags: none
- formula: round(0.45*activity + 0.35*rhythm + 0.20*longevity); archived -> min(score, 10)

## Adoption (not part of the score)
Stars 3851, forks 528 (observed 2026-08-28T04:08:24.263170+00:00)

## What it is
A PyTorch port of the official TensorFlow implementation of the Fréchet Inception Distance (FID), a metric for measuring similarity between two image datasets. It is primarily used to evaluate the visual quality of samples from generative models like GANs.

## Use cases
- compute FID score between two image folders
- evaluate GAN sample quality with PyTorch
- compare generated images to real dataset distribution
- calculate FID on GPU
- use different Inception feature layers for small datasets
- reproduce FID scores comparable to the official implementation

## When to choose
- you train GANs or diffusion models in PyTorch and need FID evaluation
- you want a pip-installable, scriptable FID calculator
- your datasets are small and you need alternative Inception feature layers
- you need results closely matching the official TensorFlow FID implementation

## When to avoid
- you need FID scores exactly comparable to papers using the official TensorFlow implementation
- you need other generative evaluation metrics like Inception Score or KID
- you don't use PyTorch and prefer the original TensorFlow tooling

## Facets
- artifact type: library
- maturity: stable
- function: machine-learning, image-processing, benchmarking, cli
- domain: deep-learning, machine-learning, computer-vision, image-processing
- platform: python, cross-platform
- tags: pytorch, fid-score, frechet-inception-distance, gan-evaluation, inception-network, generative-models, gpu

## Member repositories
- mseitzer/pytorch-fid (main) score 23

## Provenance
- Observed fields: from GitHub, fetched 2026-08-28T04:08:24.263170+00:00.
- Health v2: computed from the inputs above; adoption is never an input.
- Inferred fields (summary, facets, guidance): AI-extracted, prompt v1, taxonomy v1, on 2026-08-29T18:25:58.000757+00:00, confidence not recorded.
  - readme: https://github.com/mseitzer/pytorch-fid (fetched 2026-08-28T04:08:24.263170+00:00, sha ee9e97bdb366)
  - registry_pypi: https://pypi.org/pypi/pytorch-fid/json (fetched 2026-08-29T09:20:30.896319+00:00, sha 6306ed9c38de)
- Data as of 2026-08-30T08:39:29.467469+00:00.
