Skip to main content

PyNIPS

PyNIPS is a Python library for reading data from NIPS 360 FFS data files.

The National Military Command System Information Processing System 360 Formatted File System (NIPS 360 FFS) was a database management system used by the United States of America Military, primarily during the Vietnam War. NIPS 360 FFS runs on the IBM System/360 mainframe computers and is based on the IBM Formatted File System (FFS).

Installation

pip install pynips

See also the Getting and Installing PyNIPS in the online documentation.

Usage

See also the online documentation.

As Python library

import nips


# load the NIPS file
data_set = nips.DataSet('HES.HAMLA.67.NIPS')

for record in data_set.fixed_set:
	print(record)
	
for record in data_set.periodic_sets[0]:
	print(record)

The NIPSEXT command-line utility

A stand-alone command-line utility is provided for:

$ nipsext -h

usage: nipsext [-h] [-d] [-v] {info,rec,logical,sqlite,repl} ...

NIPS EXtraction Tool

options:
  -h, --help            show this help message and exit
  -d, --debug           Print debugging statements
  -v, --verbose         Print verbose information

commands:
  {info,rec,logical,sqlite,repl}
    info                Output information about the NIPS file.
    rec                 Output records in the recfiles file format. This is a format usable by the GNU Recutils tools.
    logical             Read and display logical records in a NIPS data file. Useful for debugging physical format.
    sqlite              Export records from NIPS file to an SQLite database.
    repl                Load the NIPS file and start an interactive REPL.

Danger's over, Banana Breakfast is saved.

Development

Building Documentation

Documentation for PyNIPS is built using Sphinx.

Install Sphinx (pip install sphinx) and run:

make -C docs/ html

to build a HTML rendering of the documentation in docs/_build_html.

Publishing to PyPi

Make sure version is set propertly in pyproject.toml and nips/__init__.py.

pip install build twine

# Build the package
python -m build

# Upload using twine
twine upload dist/*

TODOs

  • Handle continuation records
  • Handle GeoCoordinate data mode

Acknowledgments

This software was initially developed as part of the SNSF-Ambizione funded research project "Computing the Social. Psychographics and Social Physics in the Digital Age".

License

AGPL-3.0-or-later

Release files for pynips 0.2.1

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for pynips 0.2.1
File Size Uploaded
pynips-0.2.1.tar.gz 37.4 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for pynips 0.2.1
File Interpreter ABI Platform
pynips-0.2.1-py3-none-any.whl Python 3 none any Details

Total release size: 81.2 kB

Release files / pynips-0.2.1.tar.gz

Download URL pynips-0.2.1.tar.gz
Size 37.4 kB
Tags Source
SHA-256 checksum
How to use checksums
daf40b0b5cd5a277695dca01c640929d9c9c5b18657b4305234e697bbed185c9
BLAKE2b-256 checksum
How to use checksums
5924d31df551b5689a731d31100a4c06af56559a1882769ef50c7239304178b0
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/5.0.0 CPython/3.10.7

Release files / pynips-0.2.1-py3-none-any.whl

Download URL pynips-0.2.1-py3-none-any.whl
Size 43.9 kB
Tags Python 3
SHA-256 checksum
How to use checksums
7f09a30a9f0ed2effbf5862881d193edeac28baf9dfa9415ee51950946249b95
BLAKE2b-256 checksum
How to use checksums
88266b88101e4513cb721d5922d760abc14d9ec60f05f9942dc60488200a1d46
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/5.0.0 CPython/3.10.7

Release history Release notifications | RSS feed

This release

0.2.1 This release

2 release files

0.1.1

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page