Engineering Papers⌕ Search

SEARCH · Engineering Papers

Results for “PYTHON”

Search indexed NASA NTRS and DOE OSTI research on propulsion, heat transfer, battery materials and energy systems. Follow report and document links to the original sources.

Quote a phrase for an exact phrase match. Source license links do not imply unrestricted reuse.

At least 1,135 records · Page 63

DLSIA: Deep Learning for Scientific Image Analysis

DLSIA (Deep Learning for Scientific Image Analysis) is a Python-based machine learning library that empowers scientists and researchers across diverse scientific domains with a range of customizable convolutional neural network (CNN) architectures for a wide variety of tasks in image analysis to be used in downstream data processing. DLSIA features easy-to-use architectures, such as autoencoders, tunable U-Nets and parameter-lean mixed-scale dense networks (MSDNets). Additionally, this article introduces sparse mixed-scale networks (SMSNets), generated using random graphs, sparse connections and dilated convolutions connecting different length scales. For verification, several DLSIA-instantiated networks and training scripts are employed in multiple applications, including inpainting for X-ray scattering data using U-Nets and MSDNets, segmenting 3D fibers in X-ray tomographic reconstructions of concrete using an ensemble of SMSNets, and leveraging autoencoder latent spaces for data compression and clustering. As experimental data continue to grow in scale and complexity, DLSIA provides accessible CNN construction and abstracts CNN complexities, allowing scientists to tailor their machine learning approaches, accelerate discoveries, foster interdisciplinary collaboration and advance research in scientific image analysis.

97 MATHEMATICS AND COMPUTING↗

pyDiSCaMB : enabling the use of multipolar scattering factors in Phenix

Multipolar scattering models, such as the transferable aspherical atom model, account for atomic chemical interactions and provide a more accurate representation of experimental data. However, the simpler independent atom model (IAM), which assumes non-interacting atoms, is the only model available in the most widely used macromolecular refinement programs. This is primarily because IAM offers a hard-to-beat combination of computational efficiency and modelling power at typical macromolecular resolutions. By contrast, more accurate multipolar modelling has historically been limited due to its computational cost and the absence of an interface between software capable of calculating structure factors and gradients based on multipolar models and software designed for macromolecular refinement. This work introduces pyDiSCaMB , a Python software package designed to integrate between the computational crystallography toolbox ( cctbx ) and the quantum crystallography library DiSCaMB ( Densities in Structural Chemistry and Molecular Biology ), thus enabling multipolar scattering models in Phenix 's toolkit. The implementation, features and capabilities of pyDiSCaMB are presented, the runtimes for the calculation of structure factor and target gradients with respect to atomic parameters are explored, and Fourier images of electrostatic potential, electron density and deformation maps are computed as illustrative examples. The pyDiSCaMB library will make multipolar modelling widely available to the structural biology community, potentially transforming refinement and model-building for both crystallography and cryogenic electron microscopy (cryoEM).

MATTS data bank↗

Solution scattering at the Life Science X-ray Scattering (LiX) beamline

This work reports the instrumentation and software implementation at the Life Science X-ray Scattering (LiX) beamline at NSLS-II in support of biomolecular solution scattering. For automated static measurements, samples are stored in PCR tubes and grouped in 18-position sample holders. Unattended operations are enabled using a six-axis robot that exchanges sample holders between a storage box and a sample handler, transporting samples from the PCR tubes to the X-ray beam for scattering measurements. The storage box has a capacity of 20 sample holders. At full capacity, the measurements on all samples last for ∼9 h. For in-line size-exclusion chromatography, the beamline-control software coordinates with a commercial high-performance liquid chromatography (HPLC) system to measure multiple samples in batch mode. The beamline can switch between static and HPLC measurements instantaneously. In all measurements, the scattering data span a wide q -range of typically 0.006–3.2 Å −1 . Functionalities in the Python package py4xs have been developed to support automated data processing, including azimuthal averaging, merging data from multiple detectors, buffer scattering subtraction, data storage in HDF5 format and exporting the final data in a three-column text format that is acceptable by most data analysis tools. These functionalities have been integrated into graphical user interfaces that run in Jupyter notebooks, with hooks for external data analysis software.

60 APPLIED LIFE SCIENCES↗

TXM-Sandbox : an open-source software for transmission X-ray microscopy data analysis

A transmission X-ray microscope (TXM) can investigate morphological and chemical information of a tens to hundred micrometre-thick specimen on a length scale of tens to hundreds of nanometres. It has broad applications in material sciences and battery research. TXM data processing is composed of multiple steps. A workflow software has been developed that integrates all the tools required for general TXM data processing and visualization. The software is written in Python and has a graphic user interface in Jupyter Notebook . Users have access to the intermediate analysis results within Jupyter Notebook and have options to insert extra data processing steps in addition to those that are integrated in the software. The software seamlessly integrates ImageJ as its primary image viewer, providing rich image visualization and processing routines. As a guide for users, several TXM specific data analysis issues and examples are also presented.

36 MATERIALS SCIENCE↗

tomoCAM : fast model-based iterative reconstruction via GPU acceleration and non-uniform fast Fourier transforms

X-ray-based computed tomography is a well established technique for determining the three-dimensional structure of an object from its two-dimensional projections. In the past few decades, there have been significant advancements in the brightness and detector technology of tomography instruments at synchrotron sources. These advancements have led to the emergence of new observations and discoveries, with improved capabilities such as faster frame rates, larger fields of view, higher resolution and higher dimensionality. These advancements have enabled the material science community to expand the scope of tomographic measurements towards increasingly in situ and in operando measurements. In these new experiments, samples can be rapidly evolving, have complex geometries and restrictions on the field of view, limiting the number of projections that can be collected. In such cases, standard filtered back-projection often results in poor quality reconstructions. Iterative reconstruction algorithms, such as model-based iterative reconstructions (MBIR), have demonstrated considerable success in producing high-quality reconstructions under such restrictions, but typically require high-performance computing resources with hundreds of compute nodes to solve the problem in a reasonable time. Here, tomoCAM , is introduced, a new GPU-accelerated implementation of model-based iterative reconstruction that leverages non-uniform fast Fourier transforms to efficiently compute Radon and back-projection operators and asynchronous memory transfers to maximize the throughput to the GPU memory. The resulting code is significantly faster than traditional MBIR codes and delivers the reconstructive improvement offered by MBIR with affordable computing time and resources. tomoCAM has a Python front-end, allowing access from Jupyter -based frameworks, providing straightforward integration into existing workflows at synchrotron facilities.

73 NUCLEAR PHYSICS AND RADIATION PHYSICS↗

A differentiable simulation package for performing inference of synchrotron-radiation-based diagnostics

The direction of particle accelerator development is ever-increasing beam quality, currents and repetition rates. This poses a challenge to traditional diagnostics that directly intercept the beam due to the mutual destruction of both the beam and the diagnostic. An alternative approach is to infer beam parameters non-invasively from the synchrotron radiation emitted in bending magnets. However, inferring the beam distribution from a measured radiation pattern is a complex and computationally expensive task. To address this challenge we present SYRIPY ( SYnchrotron Radiation In PYthon ), a software package intended as a tool for performing inference of synchrotron-radiation-based diagnostics. SYRIPY has been developed using PyTorch , which makes it both differentiable and able to leverage the high performance of GPUs, two vital characteristics for performing statistical inference. The package consists of three modules: a particle tracker, Lienard–Wiechert solver and Fourier optics propagator, allowing start-to-end simulation of synchrotron radiation detection to be carried out. SYRIPY has been benchmarked against SRW , the prevalent numerical package in the field, showing good agreement and up to a 50× speed improvement. Finally, we have demonstrated how SYRIPY can be used to perform Bayesian inference of beam parameters using stochastic variational inference.

43 PARTICLE ACCELERATORS↗

TomoPyUI : a user-friendly tool for rapid tomography alignment and reconstruction

The management and processing of synchrotron and neutron computed tomography data can be a complex, labor-intensive and unstructured process. Users devote substantial time to both manually processing their data ( i.e. organizing data/metadata, applying image filters etc. ) and waiting for the computation of iterative alignment and reconstruction algorithms to finish. In this work, we present a solution to these problems: TomoPyUI , a user interface for the well known tomography data processing package TomoPy . This highly visual Python software package guides the user through the tomography processing pipeline from data import, preprocessing, alignment and finally to 3D volume reconstruction. The TomoPyUI systematic intermediate data and metadata storage system improves organization, and the inspection and manipulation tools (built within the application) help to avoid interrupted workflows. Notably, TomoPyUI operates entirely within a Jupyter environment. Herein, we provide a summary of these key features of TomoPyUI , along with an overview of the tomography processing pipeline, a discussion of the landscape of existing tomography processing software and the purpose of TomoPyUI , and a demonstration of its capabilities for real tomography data collected at SSRL beamline 6-2c.

73 NUCLEAR PHYSICS AND RADIATION PHYSICS↗

Framework for X-ray mirror surface shape fitting

For accurate characterization of grazing-incidence X-ray mirrors, we present a comprehensive framework to fit measured surface shapes (either slope or height) of X-ray mirrors used in synchrotron radiation and free-electron laser facilities. We summarize the closed-form expressions of some typical surface shapes of X-ray mirrors including elliptic cylinders, hyperbolic cylinders, ellipsoids, hyperboloids, and diaboloids. This framework is composed of four layers: definition of standard shapes with closed-form expressions, generation of theoretical surface with pose parameters (six degrees of freedom defining an object's position and orientation relative to a coordinate system), parameter optimization with the ability to select which parameters are fit and which are held constant, and the development of user-friendly fitting function wrappers for particular fitting tasks. A few practical fitting examples are demonstrated to verify the effectiveness of the proposed fitting framework. We discuss the physical meanings of the fitting parameters, and provide several examples using the elliptic cylinder and ellipsoid shapes to highlight some features of the framework. Moreover, we provide the presented framework as open-source codes (MATLAB and Python codes available at https://github.com/nsls2omf/xmf) to the community to encourage academic collaboration and further improvements.

36 MATERIALS SCIENCE↗

Real-space texture and pole-figure analysis using the 3D pair distribution function on a platinum thin film

An approach is described for studying texture in nanostructured materials. The approach implements the real-space texture pair distribution function (PDF), txPDF, laid out by Gong & Billinge {(2018). arXiv:1805.10342 [cond-mat]}. It is demonstrated on a fiber-textured polycrystalline Pt thin film. The approach uses 3D PDF methods to reconstruct the orientation distribution function of the powder crystallites from a set of diffraction patterns, taken at different tilt angles of the substrate with respect to the incident beam, directly from the 3D PDF of the sample. A real-space equivalent of the reciprocal-space pole figure is defined in terms of interatomic vectors in the PDF and computed for various interatomic vectors in the Pt film. Furthermore, it is shown how a valid isotropic PDF may be obtained from a weighted average over the tilt series, including the measurement conditions for the best approximant to the isotropic PDF from a single exposure, which for the case of the fiber-textured film was in a nearly grazing incidence orientation of ∼10°. Finally, an open-source Python software package, FouriGUI , is described that may be used to help in studies of texture from 3D reciprocal-space data, and indeed for Fourier transforming and visualizing 3D PDF data in general.

3D pair distribution functions↗

Growth functions of periodic space tessellations

This work analyzes the rules governing the growth of the numbers of vertices, edges and faces in all possible periodic tessellations of the 2D Euclidean space, and encodes those rules in several types of polynomial growth functions. These encodings map the geometric, combinatorial and topological properties of the tessellations into sets of integer coefficients. Several general statements about these encodings are given with rigorous mathematical proof. The variation of the growth functions is represented graphically and analyzed in orphic diagrams, so named because of their similarity to orphic art. Several examples of 3D space groups are included, to emphasize the complexity of the growth functions in higher dimensions. A freely available Python library is presented to facilitate the discovery of the growth functions and the generation of orphic diagrams.

Chemistry↗

Deep residual networks for crystallography trained on synthetic data

The use of artificial intelligence to process diffraction images is challenged by the need to assemble large and precisely designed training data sets. To address this, a codebase called Resonet was developed for synthesizing diffraction data and training residual neural networks on these data. Here, two per-pattern capabilities of Resonet are demonstrated: (i) interpretation of crystal resolution and (ii) identification of overlapping lattices. Resonet was tested across a compilation of diffraction images from synchrotron experiments and X-ray free-electron laser experiments. Crucially, these models readily execute on graphics processing units and can thus significantly outperform conventional algorithms. While Resonet is currently utilized to provide real-time feedback for macromolecular crystallography users at the Stanford Synchrotron Radiation Lightsource, its simple Python-based interface makes it easy to embed in other processing frameworks. This work highlights the utility of physics-based simulation for training deep neural networks and lays the groundwork for the development of additional models to enhance diffraction collection and analysis.

36 MATERIALS SCIENCE↗

Design of Controller Hardware-In-the-Loop Model of Microgrid with Modular Building Blocks and Automated Design Script

The scalability of controller hardware-in-the-loop (CHIL) simulation is critical for validating control coordination and energy management in microgrids with distributed energy resources, especially as these modern systems become more complex and decentralized. This paper presents a CHIL modeling methodology that combines modular building blocks with an automated design script to streamline the development of high-fidelity microgrid models. Standardized subsystem templates for resources, converters, and buses are integrated with a Python-based script that compiles structured JSON configuration files into simulation-ready initialization code. The proposed approach reduces development time, improves model consistency, and enhances simulation fidelity. The methodology is validated on a Typhoon HIL604 platform and is broadly applicable to real-time simulation of complex, networked microgrid systems. This framework establishes a foundation for automated, scalable CHIL validation and accelerates the design of next-generation distributed energy systems.

Kim, Namwon [ORNL] (ORCID:0000000200438489)↗

Normality of I-V Measurements Using ML

There is an increased interest in instrument-computing ecosystems (ICEs) that support science workflows empowered by AI-automated experiments and computations in diverse areas. In particular, electrochemistry ICEs are promising for accelerating the design and discovery of electrochemical systems for energy storage and conversion, by automating significant parts of workflows that combine synthesis and characterization experiments with computations. They require the integration of flow controllers, solvent containers, pumps, fraction collectors, and potentiostats, all connected to an electrochemical cell, as illustrated in Fig. 1. These are specialized instruments with custom software that is not originally designed for network integration. We developed network and software solutions for electrochemical workflows that adapt system and instrument settings in real-time for multiple rounds of experiments. In particular, we developed Python wrappers for Application Programming Interfaces (APIs) of instrument commands and Pyro client-server modules that enable them to be executed from remote computers. The entire workflow is orchestrated by a Jupyter notebook running on a remote computer.

Al Najjar, Anees↗

Controller Hardware-in-the-Loop Modeling and Operation of a High-Power DC Charging Hub

High-power charging (HPC) concept will be a critical enabler for the wide-scale adoption and integration of electric vehicles (EVs). HPC hubs will have a significant impact on achieving this goal, particularly when considering the charging requirements of next-generation medium and heavy-duty vehicles (MD/HD) used in various vocational scenarios. This emphasizes the significance of evaluating and confirming the technical planning and multi-level operation of HPC hubs through modeling, protocol implementation, and simulation before hardware demonstration. The focus of this study is to develop the architecture, modeling, communication, and real-time controller hardware-in-the-loop (C-HIL) simulation of HPC hubs using the DC distribution system approach. Specifically, this work demonstrates the practical implementation of a custom Smart Energy Management System (SEMS) for a real-time C-HIL HPC hub simulation using the Open Charge Point Protocol (OCPP) for communication. OCPP is implemented on the Node-Red framework and the custom controller is executed in Python. We developed a rule-based controller to demonstrate the proposed approach.

ADVANCED PROPULSION SYSTEMS↗

Virtual Trajectories for I–24 MOTION: Data and Tools

This paper introduces a toolbox for generating virtual trajectories, which we call VT-tools v1.0, to address challenges in analyzing large but imperfect trajectory datasets. VT-tools v1.0 is able to generate virtual trajectories from large raw datasets that are typically challenging to process due to their size. We also provide a set of these virtual trajectories resulting from I–24 MOTION INCEPTION v1.0 data and demonstrate the practical utility of these trajectories in as-sessing speed variability and travel times across different lanes within the INCEPTION dataset. The virtual trajectory toolbox opens future research on traffic waves and their impact on energy. The VT-tools v1.0 Python implementation and sample data are publicly available at https://i24motion.org.

42 ENGINEERING↗

Sparse Deep Neural Network Inference using different Programming Models

Sparse deep neural networks have gained increasing attention recently in achieving speedups on inference with reduced memory footprints. However, the real-world applications are little shown with specialized optimizations, yet a wide variety of DNN tasks remain dense without exploiting the advantages of sparsity in networks. Recent work presented by MIT/IEEE/Amazon GraphChallenge has demonstrated significant speedups and various techniques. Still, we find that there is limited investigation of the impact of various Python and C\slash C++ based programming models to explore new opportunities in general cases. In this work, we provide performance evaluation through different programming models using CuPy, cuSPARSE, and OpenMP to discuss the advantages and disadvantages of our sparse implementations on single-GPU and multiple GPUs of NVIDIA DGX-A100 40GB/80GB platforms.

machine learning, HPC↗

Characterization and Optimization of the Fitting of Quantum Correlation Functions

This case study presents a characterization and optimization of an application code for extracting parton distribution functions from high energy electron-proton scattering data. Profiling this application code reveals that the phase-space density computation accounts for 93% of the overall execution time for a single iteration on a single core. When executing multiple iterations in parallel on a multicore system, the application spends 78% of its overall execution time idling due to load imbalance. We address these issues by first transforming the application code from Python to C++ and then tackling the application load imbalance via a hybrid scheduling strategy that combines dynamic and static scheduling. These techniques result in a 62% reduction in CPU idle time and a 2.46x speedup in overall execution time per node. In addition, the typically enabled power-management mechanisms in supercomputers (e.g., AMD Turbo Core, Intel Turbo Boost, and RAPL) can significantly impact intra-node scalability when more than 50% of the CPU cores are used. This finding underscores the importance of understanding system interactions with power management, as they can adversely impact application performance, and highlights the necessity of intra-node scaling tests to identify performance degradation that inter-node scaling tests might otherwise overlook.

Chuang, Pi-Yueh [Virginia Tech,Dept. of Computer S↗

Descriptor: High Temporal Resolution Meteorological Data at Oak Ridge Reservation (ORR-HiResMet)

Access to continuous, quality assessed meteorological data is critical for understanding the climatology and atmospheric dynamics of a region. Research facilities like Oak Ridge National Laboratory (ORNL) rely on such data to assess site-specific climatology, model potential emissions, establish safety baselines, and prepare for emergency scenarios. To meet these needs, on-site towers at ORNL collect meteorological data at 15-minute and hourly intervals. However, data measurements from meteorological towers are affected by sensor sensitivity, degradation, lightning strikes, power fluctuations, glitching, and sensor failures, all of which can affect data quality. To address these challenges, we conducted a comprehensive quality assessment and processing of five years of meteorological data collected from ORNL at 15-minute intervals, including measurements of temperature, pressure, humidity, wind, and solar radiation. The time series of each variable was pre-processed and gap-filled using established meteorological data collection and cleaning techniques, i.e., the time series were subjected to structural standardization, data integrity testing, automated and manual outlier detection, and gap-filling. The data product and highly generalizable processing workflow developed in Python Jupyter notebooks are publicly accessible online. As a key contribution of this study, the evaluated 5-year data will be used to train atmospheric dispersion models that simulate dispersion dynamics across the complex ridge-and-valley topography of the Oak Ridge Reservation in East Tennessee.

Steckler, Morgan R. [Oak Ridge National Laboratory↗