Skip to main content

Build Status

Ask DeepWiki

SurfaceTopography

Read and analyze surface topographies with Python. This code implements basic classes for handling uniform and nonuniform surface topography data. It contains a rich set of import filters for experimental surface topography data. Surface topographies can be easily analyzed using standard (rms height, power spectrum, ...) and some special purpose (autocorrelation function, variable bandwidth analysis, ...) statistical techniques.

Quick Start

from SurfaceTopography import read_topography

# Read a topography file (format is auto-detected)
topography = read_topography('surface.opd')

# Get basic properties
print(f"Grid size: {topography.nb_grid_pts}")
print(f"Physical size: {topography.physical_sizes}")
print(f"RMS height: {topography.Sq()}")

# Compute the power spectral density (PSD)
q, psd = topography.power_spectrum_from_profile()

# Compute the autocorrelation function (ACF)
r, acf = topography.autocorrelation_from_profile()

# Plot the topography
import matplotlib.pyplot as plt
plt.pcolormesh(*topography.positions_and_heights())
plt.colorbar(label='Height')
plt.show()

Supported File Formats

SurfaceTopography reads more than 40 file formats of commercial surface profilometers and scanning probe microscopes (see the full list):

Format Description
al3d Alicona AL3D files
asc ASCII text files (generic)
bcr BCR-STM files
datx Zygo DATX files
di Digital Instruments / Bruker AFM files
ezd Nanosurf EZD files
frt FRT profilometer files
gwy Gwyddion GWY files
h5 HDF5 files
hgt NASA SRTM HGT elevation files
ibw Igor Pro binary wave files (Asylum Research)
jpk JPK Instruments files
lext Olympus LEXT files
mat MATLAB .mat files
mdt NT-MDT (Solver, Ntegra) AFM files
metropro Zygo MetroPro files
mi Agilent / Molecular Imaging files
mitutoyo Mitutoyo surface roughness files
mnt Digital Surf Mountains MNT files
nc NetCDF files
nmm Nanomeasuring machine (NMM) files
nms Nanofocus NMS files
npy NumPy binary files
npz NumPy array archives
oir Olympus OIR files
opd Wyko OPD files
opdx Bruker Dektak OPDx files
os3d Digital Metrology OmniSurf3D files
plu Sensofar PLU files
plux Sensofar PLUX files
poir Olympus POIR (zip) files
ps Park Systems TIFF files
qep Mahr MarWin QEP profile archives
sdf ISO 25178-71 SDF files
sur Digital Surf SUR files
tmd TrueMap TMD files
vk Keyence VK files
wsxm WSxM files
x3p ISO 25178-72 X3P files
xyz XYZ point cloud files
zmg KLA Zeta ZMG files
zon Keyence ZON files

If you use this code, please cite:

Documentation

This README file contains a brief introduction into the code. The full documentation can be found at https://contactengineering.github.io/SurfaceTopography/.

Installation

Detailed instructions for the installation are provided in the documentation.

The most basic configuration of SurfaceTopography installs all requirements autonomously: python3 -m pip install SurfaceTopography

If you need an editable install (e.g. for development purposes), make sure you disable build isolation:

python3 -m pip install --no-build-isolation -e .

You need to manually install ninja, meson-python, pytest, DiscoverVersion and numpy before:

python3 -m pip install ninja meson-python pytest DiscoverVersion numpy

MPI-parallel (domain-decomposed) topographies need the mpi extra, with mpi4py and muGrid compiled against your MPI library:

CC=mpicc CXX=mpicxx python3 -m pip install --no-binary mpi4py --no-binary muGrid SurfaceTopography[mpi]

Funding

Development of this project is funded by the European Research Council within Starting Grant 757343 and by the Deutsche Forschungsgemeinschaft within projects PA 2023/2 and EXC 2193.

Metadata

Release files for SurfaceTopography 1.28.0

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

Source distribution (sdist)

Source distribution for SurfaceTopography 1.28.0
File Size Uploaded Provenance Actions
surfacetopography-1.28.0.tar.gz 1.5 MB Without provenance Details for surfacetopography-1.28.0.tar.gz

Release files / surfacetopography-1.28.0.tar.gz

Download URL surfacetopography-1.28.0.tar.gz
Size 1.5 MB
Tags Source
SHA-256 checksum
How to use checksums
a1d3b73d771da585725b200639de4ec6a69d64be41f70e5af58fa0acbcdce06a
BLAKE2b-256 checksum
How to use checksums
13dc011f39931dc9953419f394afc51ea97a9c29398312287c9769fe0f995099
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.13.16

Security for SurfaceTopography 1.28.0

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Release history Release notifications | RSS feed

This release

1.28.0 This release

1 release file No provenance

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