Skip to main content

NMR spectra signal processing through pipelines

Reason this release was yanked:

CCP4 Bug

Project description

nmrPype

Python implementation of command-line program nmrpipe, using linux pipelines to process NMR data.

Installation

Installing nmrPype can be done by through pip:

# Install prerequisites
pip install numpy scipy
# Install program
pip install nmrPype

A virtual environment or conda environment is recommended for using nmrPype. If using conda, numpy and scipy can be installed using conda install.

Note

This is made for Python 3.10 or above. Some of the code requires Python 3.10's features such as match-case statements.

Python 3.12 is recommended as development is done with 3.12, but testing is done to assure that 3.10 is supported.

Usage

nmrPype can be used in through two methods: Command-line and Script

Command-line

nmrPype -in [inFile] -fn fnName -out [outFile] [-ov]

Functions:

FT                  Perform a Fourier transform (FT) on the data
ZF                  Perform a Zero Fill (ZF) Operation on the data
SP (SINE)           Adjustable Sine Bell
PS                  Perform a Phase Correction (PS) on the data
YTP (TP, XY2YX)     2D Plane Transpose
ZTP (XYZ2ZYX)       3D Matrix Transpose
ATP (XYZA2AYZX)     4D Matrix Transpose (unimplemented)
NULL                Null Function, does not apply any function

Run the nmrPype --help command to see a list of more options.

Script

In a Python script or jupyter notebook use the following line:

import nmrPype

I recommend setting the import as pype for simplification.

Example

import nmrPype as pype

df = pype.DataFrame("h.fid") # Load NMR data file into script
df.array() # Display spectral data array

Building From Source

Building using Pip

  1. Install prerequisites
pip install numpy scipy
  1. Clone the repository
git clone https://github.com/PhiMykah/nmrPype
  1. Install in development mode with pip:
cd nmrPype
pip install -e .

Building using Conda

With conda, the environment.yml file can be used to obtain the development environment.

  1. Clone the repository
git clone https://github.com/PhiMykah/nmrPype
  1. Copy the source conda environment
cd nmrPype
conda env create -f environment.yml --name nmrpype
  • You can set the name to anything you wish, but typically my convention is to have the environments lowercase
  1. Install in development mode with pip:
pip install -e .

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

nmrPype-1.0.0.tar.gz (59.2 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

nmrPype-1.0.0-py3-none-any.whl (74.9 kB view details)

Uploaded Python 3

File details

Details for the file nmrPype-1.0.0.tar.gz.

File metadata

  • Download URL: nmrPype-1.0.0.tar.gz
  • Upload date:
  • Size: 59.2 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.0.0 CPython/3.12.0

File hashes

Hashes for nmrPype-1.0.0.tar.gz
Algorithm Hash digest
SHA256 d5127a217d53246accf9d6c7b6c416c51a5df862e5bbfd3c81109e34f23bb738
MD5 4cbace50d0b5111d4bf6e30b0968d425
BLAKE2b-256 72e6d5f1182468a1bac204779c561d8762f7fafb41c38c405f77d18bfdb5d851

See more details on using hashes here.

File details

Details for the file nmrPype-1.0.0-py3-none-any.whl.

File metadata

  • Download URL: nmrPype-1.0.0-py3-none-any.whl
  • Upload date:
  • Size: 74.9 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.0.0 CPython/3.12.0

File hashes

Hashes for nmrPype-1.0.0-py3-none-any.whl
Algorithm Hash digest
SHA256 085578c5295620323a6226db1efafa963080656cf3dca6919a265649d7be2fab
MD5 d11d15734d0be28b8a145ca81d0cf500
BLAKE2b-256 57e3682394446ce9de64ccb9b3c79d4192897acef787000706366461c3bc6ec8

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page