Skip to main content

Standalone crystal-to-cluster builder

Project description

<<<<<<< HEAD

nanobuilder

In this repository are stored the Jupyter Notebooks used to build bare nanoparticle and polarised nanoparticle(including virtual sites) of platonic shapes.

NanoBuilder

NanoBuilder is a standalone crystal-to-cluster package for the QPIAI Matter Group. It borrows architectural ideas from ASE, but it does not import or depend on ASE.

Full usage and project-layout documentation:

Quick setup options:

  • local virtual environment with make venv install-dev
  • smoke checks with make smoke
  • Docker-based run with docker build -t nanobuilder:local . && docker run --rm nanobuilder:local
  • CI workflow in .github/workflows/ci.yml

Current features

  • Read CIF files with multiple data blocks, loops, cartesian or fractional atom sites, and symmetry-operation expansion.
  • Build bulk crystal prototypes from formulas such as Au, Cu, or simple alloys with automatic lattice inference for supported materials.
  • Create finite particles from repeated crystals using shape cuts and Wulff-like facet rules.
  • Generate advanced motifs such as icosahedra, decahedra, and octahedra.
  • Build simple slabs for common surfaces such as FCC(100), FCC(111), BCC(100), and BCC(110).
  • Create simple linear polymers and attach them to clusters.
  • Export generated structures to XYZ.

Package layout

  • nanobuilder/core: atom, lattice, structure, and geometry primitives
  • nanobuilder/io: CIF parsing and composition parsing
  • nanobuilder/build: bulk and surface constructors
  • nanobuilder/builders: generic shape and Wulff-style builders
  • nanobuilder/lattice: prototype crystal definitions
  • nanobuilder/cluster: advanced nanoparticle motifs
  • nanobuilder/spacegroup: lightweight symmetry expansion tools
  • nanobuilder/materials: reference lattice data and inference
  • nanobuilder/polymers: polymer generation and attachment
  • nanobuilder/export: structure writers
  • tests: smoke and feature tests
  • tools: helper scripts
  • examples: runnable examples
  • doc: project documentation
  • requirements: dependency groups for base, development, and docs

Quick examples

Build a bulk reference from composition:

from nanobuilder.build import bulk

au = bulk("Au")

Build a cluster from CIF input:

from nanobuilder.io import read_cif
from nanobuilder.builders import ClusterBuilder, SphereShape

structure = read_cif("input.cif")
cluster = ClusterBuilder(structure).build(SphereShape(radius=12.0), repetitions=(8, 8, 8))

Build an advanced motif:

from nanobuilder.cluster import IcosahedronBuilder

particle = IcosahedronBuilder("Au", shells=4).build()

67d611c (add files)

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

nanobuilder-0.1.0.tar.gz (32.3 kB view details)

Uploaded Source

Built Distribution

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

nanobuilder-0.1.0-py3-none-any.whl (35.9 kB view details)

Uploaded Python 3

File details

Details for the file nanobuilder-0.1.0.tar.gz.

File metadata

  • Download URL: nanobuilder-0.1.0.tar.gz
  • Upload date:
  • Size: 32.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.10.20

File hashes

Hashes for nanobuilder-0.1.0.tar.gz
Algorithm Hash digest
SHA256 8a550e620bbfb24308093af3fc4dd0deb1e78f8b7ae64f814c1339f349e8e6b6
MD5 ef7bc63ab0084810409fc0b8da53217f
BLAKE2b-256 9a9e9f000bd42ad51cba454261f322b063c31b7886995f848e21ebaa21c93f11

See more details on using hashes here.

File details

Details for the file nanobuilder-0.1.0-py3-none-any.whl.

File metadata

  • Download URL: nanobuilder-0.1.0-py3-none-any.whl
  • Upload date:
  • Size: 35.9 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.10.20

File hashes

Hashes for nanobuilder-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 360ba575fe4f79edf4d45c818112ee35e87067cfc613c9b4487829f60d54adb9
MD5 56f4617f85cd6b8b7af661cc2b78228b
BLAKE2b-256 1f860624538f8e8e66194a513a3929946677be1476fdafcb4438f8f4ded11e92

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