Skip to main content

density_calculator: Calculate mFo-DFc density with Clipper through Gemmi!

Project description

Density Calculator

Density Calculator is a library for calculating a $mFo-DFc$ maps from gemmi in-memory objects.

Installation

pip install density-calculator

Usage

Function Signature:

density_calculator.calculate(structure: gemmi.Structure, mtz: gemmi.Mtz, column_names: List[str]) -> gemmi.Mtz

Example Use:

import density_calculator
import gemmi

mtz: gemmi.Mtz = gemmi.read_mtz_file("reflections.mtz")
st: gemmi.Structure = gemmi.read_structure("model.pdb")

# Calculate the difference map using density_calculator
difference_mtz: gemmi.Mtz = density_calculator.calculate(st, mtz, ["FP", "SIGFP"])

# Transform the difference_mtz into a map for calculation use
difference_map: gemmi.FloatGrid = difference_mtz.transform_f_phi_to_map("DELFWT", "PHDELWT")

Development

pip install --no-build-isolation --config-settings=editable.rebuild=true -Cbuild-dir=build -ve .

Project details


Download files

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

Source Distributions

No source distribution files available for this release.See tutorial on generating distribution archives.

Built Distributions

density_calculator-0.1-cp312-abi3-musllinux_1_1_x86_64.whl (6.6 MB view hashes)

Uploaded CPython 3.12+ musllinux: musl 1.1+ x86-64

density_calculator-0.1-cp312-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (6.2 MB view hashes)

Uploaded CPython 3.12+ manylinux: glibc 2.17+ x86-64

density_calculator-0.1-cp312-abi3-macosx_11_0_arm64.whl (5.6 MB view hashes)

Uploaded CPython 3.12+ macOS 11.0+ ARM64

density_calculator-0.1-cp312-abi3-macosx_10_14_x86_64.whl (5.9 MB view hashes)

Uploaded CPython 3.12+ macOS 10.14+ x86-64

density_calculator-0.1-cp311-cp311-musllinux_1_1_x86_64.whl (6.6 MB view hashes)

Uploaded CPython 3.11 musllinux: musl 1.1+ x86-64

density_calculator-0.1-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (6.2 MB view hashes)

Uploaded CPython 3.11 manylinux: glibc 2.17+ x86-64

density_calculator-0.1-cp311-cp311-macosx_11_0_arm64.whl (5.6 MB view hashes)

Uploaded CPython 3.11 macOS 11.0+ ARM64

density_calculator-0.1-cp311-cp311-macosx_10_14_x86_64.whl (5.9 MB view hashes)

Uploaded CPython 3.11 macOS 10.14+ x86-64

density_calculator-0.1-cp310-cp310-musllinux_1_1_x86_64.whl (6.6 MB view hashes)

Uploaded CPython 3.10 musllinux: musl 1.1+ x86-64

density_calculator-0.1-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (6.2 MB view hashes)

Uploaded CPython 3.10 manylinux: glibc 2.17+ x86-64

density_calculator-0.1-cp310-cp310-macosx_11_0_arm64.whl (5.6 MB view hashes)

Uploaded CPython 3.10 macOS 11.0+ ARM64

density_calculator-0.1-cp310-cp310-macosx_10_14_x86_64.whl (5.9 MB view hashes)

Uploaded CPython 3.10 macOS 10.14+ x86-64

density_calculator-0.1-cp39-cp39-musllinux_1_1_x86_64.whl (6.6 MB view hashes)

Uploaded CPython 3.9 musllinux: musl 1.1+ x86-64

density_calculator-0.1-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (6.2 MB view hashes)

Uploaded CPython 3.9 manylinux: glibc 2.17+ x86-64

density_calculator-0.1-cp39-cp39-macosx_11_0_arm64.whl (5.6 MB view hashes)

Uploaded CPython 3.9 macOS 11.0+ ARM64

density_calculator-0.1-cp39-cp39-macosx_10_14_x86_64.whl (5.9 MB view hashes)

Uploaded CPython 3.9 macOS 10.14+ x86-64

Supported by

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