# tomgoldstein/loss-landscape

Code for visualizing the loss landscape of neural nets

Repository: https://github.com/tomgoldstein/loss-landscape
Canonical: https://ross.abutalabs.com/products/loss-landscape
Language: Python
License: MIT
License Family: permissive
Last push: 2022-04-05T19:28:36+00:00

## Health v2 (maintenance only)
Score: 32/100 (v2, computed 2026-09-03T02:20:16.233290+00:00)
- activity 0, release rhythm 35, longevity 100
- inputs: {"age_days": 3092, "days_push": 1611, "days_rel": null, "gap_med": null, "n_releases_24m": 0}
- flags: no_releases
- formula: round(0.45*activity + 0.35*rhythm + 0.20*longevity); archived -> min(score, 10)

## Adoption (not part of the score)
Stars 3199, forks 440 (observed 2026-08-28T04:07:48.422866+00:00)

## What it is
PyTorch code for visualizing the loss landscape of neural networks, from the NIPS 2018 paper 'Visualizing the Loss Landscape of Neural Nets'. It computes and plots 1D/2D loss surfaces along random directions near trained parameters, with MPI-based multi-GPU/multi-node parallelism and HDF5 output.

## Use cases
- visualize the loss landscape of a pretrained neural network
- plot 1D linear interpolation between two model minimizers
- compare flatness of minima trained with different batch sizes
- render 2D loss surface plots for a CIFAR-10 model
- study how skip connections affect loss geometry

## When to choose
- you have a pretrained PyTorch model and want to visualize its loss surface
- you need reproducible code for the NIPS 2018 loss landscape paper
- you want MPI-parallel loss computation across multiple GPUs or nodes

## When to avoid
- you need a maintained library with recent PyTorch support - it targets PyTorch 0.4
- you want interactive visualization rather than script-generated plots
- your models are not PyTorch state_dicts for CIFAR-10-style architectures

## Facets
- artifact type: library
- maturity: maintenance
- function: data-visualization, machine-learning, gpu-computing
- domain: deep-learning, data-visualization, machine-learning
- platform: python
- tags: pytorch, loss-landscape, hdf5, mpi, research-code, nips-2018, linux, gpu

## Member repositories
- tomgoldstein/loss-landscape (main) score 32

## Provenance
- Observed fields: from GitHub, fetched 2026-08-28T04:07:48.422866+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-30T07:24:51.239897+00:00, confidence not recorded.
  - readme: https://github.com/tomgoldstein/loss-landscape (fetched 2026-08-28T04:07:48.422866+00:00, sha e53a41879d56)
- Data as of 2026-08-30T08:39:29.467469+00:00.
