FITS Image — BITPIX 16 with BZERO Unsigned Trick (.fits)
FITS has no unsigned 16-bit type, so unsigned data is stored signed with BZERO = 32768 and recovered as BZERO + BSCALE * stored. Every stored value in this image is negative, so a reader that ignores the scaling returns an entirely negative frame while parsing the file perfectly.
| Field | Value |
|---|---|
| BITPIX | 16 (signed, big-endian) |
| BZERO | 32768 |
| BSCALE | 1 |
| Rule | physical = BZERO + BSCALE * stored |
| Stored [0,0] | -30368 |
| Physical [0,0] | 2400 |
| Stored range | -30368 to -1974 — all negative |
| Physical range | 2400 to 30794 |
Specifications
- Bitpix
- 16
- Bzero
- 32768
- Bscale
- 1
- Stored Range
- -30368 to -1974
- Physical Range
- 2400 to 30794
- Byte Order
- big-endian
- Every Stored Value Negative
- true
Testing contract
Expected to pass- Scenario
- Read the primary array and apply BZERO and BSCALE before comparing pixel values.
- Expected result
- Scaled values run from 2400 to 30794 and are all positive, whereas the raw stored array runs from -30368 to -1974 and contains no positive value at all.
What is a .fits file?
FITS (.fits, Flexible Image Transport System) is the standard binary format in astronomy. It pairs human-readable 80-character header cards (in 2880-byte blocks) with binary image or table data, storing pixel arrays, coordinates, and instrument metadata. It has been the astronomical archive format for decades.
How to use this file
Use an example .fits file to test FITS readers (astropy, CFITSIO, DS9), header-card parsing, and image or table extraction, or to verify block-alignment handling.
How to use this file for testing
“FITS Image — BITPIX 16 with BZERO Unsigned Trick (.fits)” is a deterministic Novus Examples fixture for Scientific data, Serialization testing. Citation catalogs (BibTeX, RIS), chemistry structures (MDL Molfile, PDB), and gridded binary data (NetCDF, FITS) — for testing reference managers, molecule viewers, and scientific-data loaders.
Documented properties for this file: FITS · 5,760 bytes. Compare results against paired or grouped companions on this page when present (clean↔damaged, searchable↔scanned, or format twins) so scores stay reproducible across runs.
Download the file once, keep the path stable in CI or local scripts, and treat the spec table as the contract: dimensions, seeds, field lists, and roles are intentional. Corrupt or invalid samples are labelled as such — expect parsers to fail loudly rather than silently accept them.
Scientific fixtures are small, valid, and fully synthetic — no real organism, patient, sample, or observation. Point your parser or loader at the file and check it reads the documented records, variables, or headers; binary formats ship a readable twin or metadata listing for comparison.
Related files
- fitsFITS BINTABLE — Typed Columns with TUNIT (.fits)A FITS binary table with four typed columns, big-endian numerics packed with no inter-field padding and TUNIT declaring milli-jansky on the two flux columns. It is the fixture for a table reader that has to build a row struct from TFORM codes rather than guess widths.

- fitsFITS Header-Only — Valid File With No Pixels (.fits)A completely valid FITS file consisting of one 2880-byte header block and no data unit, which the standard permits whenever NAXIS is 0. It separates readers that model the data array as optional from readers that treat 'no pixels' as corruption.

- fitsFITS Long Header — Cards Across Several 2880-Byte Blocks (.fits)A header of 47 cards, so END lands well past the first 2880-byte block, alongside repeated HISTORY and COMMENT cards that legally share a keyword. A parser that reads one block and stops never sees END and truncates the metadata.

- fitsFITS Multi-Extension — Empty Primary plus SCI and MASK (.fits)A three-HDU FITS file whose primary unit is header-only (NAXIS = 0) with the real data in named SCI and MASK extensions. A reader that only ever looks at HDU 0 reports an empty file, which is exactly the bug this fixture is built to catch.

- fitsFITS with World Coordinate System — Tangent Plane (.fits)A 32-bit integer image carrying a complete tangent-plane WCS: 1-based CRPIX reference pixels, a deliberately negative CDELT1 so right ascension runs the other way, and an ICRS frame. It targets the two mistakes every WCS implementation makes first, the 1-based origin and the flipped axis.

- binDICOM-Shaped Part 10 File — Explicit VR, Synthetic Phantom (.bin)A DICOM Part 10 file built byte by byte: 128-byte preamble, the DICM magic, an explicit-VR file meta group and a 27-element dataset ending in 16-bit pixel data. Every identifier is invented: the patient name is SYNTHETIC^PHANTOM, the instance UIDs sit under the unregistered 2.25 UUID arc, and the pixels are a generated pattern. There is no protected health information here and nothing in the file refers to a real person, device or study.

Generated by generation/scientific.py. Free for any use, no attribution required — license.