Search NASA⌕ Search

SEARCH · Search NASA

Results for “Python script”

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 91 records · Page 5

Elasto-viscoplastic fast Fourier transform modeling framework for assessing microstructural effects on stress intensity factors characterizing fracture toughness

A large-strain elasto-viscoplastic fast Fourier transform (LS-EVPFFT) model with non-periodic (NP) velocity-based boundary conditions is adapted to simulate the sensitivity of stress intensity factors on microstructure for 304L stainless steel. The material was characterized via electron backscattered diffraction (EBSD) serial-sectioning to obtain a measured 3-D microstructural cell to perform simulations. The NP-LS-EVPFFT model, including the simulation setup and boundary conditions, was verified using a crystal plasticity finite element (CPFE) model. To this end, the generation of meshes of notched specimens was developed, which involved creating Python scripts for mesh “cutting” in Abaqus, and Sculpt scripts in Cubit for meshing of the measured microstructural cell processed with DREAM.3D. The complexity of the mesh preparation highlighted the advantages of the FFT-based model, which circumvents the mesh generation process. Given the efficiency of the FFT-based model, statistical distribution of stress intensity factors in function of crystal orientation at the crack tip, grain structure, and crystallographic texture surrounding the crack tip were predicted. Further, the distributions reveal about 10% variation of stress intensity factors with microstructure with the most significant sensitivity found to be the crystal orientation at the crack tip. The methodology developed in this work is discussed as a practical simulation tool for predicting the sensitivity of stress intensity factors on microstructural variability in metallic materials.

36 MATERIALS SCIENCE↗

Catalight─An Open-Source Automated Photocatalytic Reactor Package Illustrated through Plasmonic Acetylene Hydrogenation

An open-source and modular Python package, Catalight, is developed and demonstrated to automate (photo)catalysis measurements. (Photo)catalysis experiments require studying several parameters to evaluate performance, including the temperature, gas flow rate and composition, illumination power, and spectral profile. Catalight orchestrates measurements over this complicated parameter space and systematically stores, analyzes, and visualizes the results. To showcase the capabilities of Catalight, we perform an automated apparent activation barrier measurement of acetylene hydrogenation over a plasmonic AuPd catalyst on an Al 2 O 3 support, simultaneously varying laser power, wavelength, and temperature in a multiday experiment controlled by a simple Python script. Our chemical results unexpectedly show an increased activation barrier upon light excitation, contrary to previous findings for other plasmonic reactions and catalysts. We show that the reaction rate order with respect to both acetylene and hydrogen remains unchanged upon illumination, suggesting that molecular surface coverage is not changed by light. By analyzing the inhomogeneity of the laser-induced heating, we attribute these results to a partial photothermal effect combined with a photochemical/hot electron-driven mechanism. In conclusion, our findings highlight the capabilities of a new experiment automation tool; explore the photocatalytic mechanism for an industrially relevant reaction; and identify systematic sources of error in canonical photocatalysis experimental procedures.

Catalysts↗

StaNdaRT: a repository of standardised test models and outputs for supernova radiative transfer

We present the first results of a comprehensive supernova (SN) radiative-transfer (RT) code-comparison initiative (StaNdaRT), where the emission from the same set of standardised test models is simulated by currently used RT codes. We ran a total of ten codes on a set of four benchmark ejecta models of Type Ia SNe. We consider two sub-Chandrasekhar-mass (M tot = 1.0 M ⊙ ) toy models with analytic density and composition profiles and two Chandrasekhar-mass delayed-detonation models that are outcomes of hydrodynamical simulations. We adopt spherical symmetry for all four models. The results of the different codes, including the light curves, spectra, and the evolution of several physical properties as a function of radius and time are provided in electronic form in a standard format via a public repository. We also include the detailed test model profiles and several Python scripts for accessing and presenting the input and output files. We also provide the code used to generate the toy models studied here. In this paper, we describe the test models, radiative-transfer codes, and output formats in detail, and provide access to the repository. We present example results of several key diagnostic features.

73 NUCLEAR PHYSICS AND RADIATION PHYSICS↗

Serpent and MCNP Calculations of the Energy Deposition in the Transformational Challenge Reactor

This paper focuses on the calculation of the energy deposition in the Transformational Challenge Reactor by two major Monte Carlo codes: Serpent and MCNP. The first software computation relies on Kinetic Energy Released per unit Mass (KERMA) factors while the second one relies on Q-values. The results from these two independent computation methodologies are in very good agreement; however, Serpent runs much faster than MCNP (for the same computational model) and allows for a detailed energy deposition distribution from a 1-mm-side square mesh with a relative statistical error between 0.5% and 1%. This detailed energy deposition is suitable for multiphysics analyses aimed at design optimizations. In order to calculate the energy deposition, Serpent needs enhanced ACE files (distributed by the software developers). Unlike other Monte Carlo software that uses inputs based on Python or Java languages, the Serpent input syntax is very similar to that of MCNP; a Python script can convert a MCNP input to a Serpent input in seconds. For simulations not requiring the calculation of the energy deposition, Serpent can also read nuclear data from MCNP ACE files, which eventually improves the comparison of the results of the two codes.

22 GENERAL STUDIES OF NUCLEAR REACTORS↗

A New Integrated Analysis Suite for Fast-Ion Study in KSTAR

Here, an integrated workflow for fast-ion analysis was developed by adapting the One Modeling Framework for Integrated Task (OMFIT) workflow manager to support a standard and unified analysis platform for KSTAR users. The newly established analysis suite offers a graphical user interface–based workflow to enable users to readily access and handle experimental data archived in various data formats and servers. Further, users can analyze the data by importing modules designed for conducting certain tasks, such as profile fitting, equilibrium reconstruction, and postprocessing of tokamak data. The procedures for preparing the inputs for fast-ion simulations are streamlined by a common workflow manager, which enables the parallel processing of various tasks to efficiently analyze large fast-ion datasets. The OMFIT platform comprises a flexible Python-based application that enables users to freely manipulate the Python scripts for applications that are unavailable in the standard workflow. The framework also offers mapping tools to translate the output data into the Integrated Modeling and Analysis Suite format to maintain application compatibility for future ITER burning plasma experiments.

70 PLASMA PHYSICS AND FUSION TECHNOLOGY↗

Velocity Dispersion σ aper Aperture Corrections as a Function of Galaxy Properties from Integral-field Stellar Kinematics of 10,000 MaNGA Galaxies

Abstract The second moment of the stellar velocity within the effective radius, denoted by σ e 2 , is a crucial quantity in galaxy studies, as it provides insight into galaxy properties and their mass distributions. However, large spectroscopic surveys typically do not measure σ e directly, instead providing σ aper , the second moment of the stellar velocity within a fixed fiber aperture. In this paper, we derive an empirical aperture correction formula, given by σ aper / σ e = ( R aper / R e ) α , using spatially resolved stellar kinematics extracted from approximately 10,000 Sloan Digital Sky Survey–Mapping Nearby Galaxies at Apache Point Observatory integral field unit observations. Our analysis reveals a strong dependence of α on the r -band absolute magnitude M r , g – i color, and Sérsic index n Ser , where α values are lower for brighter, redder galaxies with higher Sérsic indices. Our results demonstrate that the aperture correction derived from previous literature on early-type galaxies cannot be applied to predict the aperture corrections for galaxies with intermediate Sérsic indices. We provide a lookup table of α values for different galaxy types, with parameters in the ranges of −18 > M r > −24, 0.4 < g – i < 1.6, and 0 < n Ser < 8. A Python script is provided to obtain the correction factors from the lookup table.

Astronomy & Astrophysics↗

Heat load measurements for the PIP-II pHB650 cryomodule

Phase-3 testing of the pHB650 cryomodule at the PIP-II Injector Test Facility was conducted to evaluate the effectiveness of heat load mitigations performed after earlier phases of testing and to continue pinpointing any sources of unexpectedly high heat loads.. The programme measured HTTS, LTTS, and 2 K isothermal/non-isothermal loads under "standard", "linac", and "simulated dynamic" operating modes, recording data both inside the cryomodule and across the bayonet can circuits. Thermal-acoustic oscillations were eliminated by replacing the original G10 cooldown-valve stem with a stainless-steel stem fitted with wipers. A newly developed Python script automated acquisition of ACNET data, performed real-time heat-load calculations, and generated plots and tables that were posted to the electronic logbook within minutes, vastly reducing manual effort and accelerating feedback between SRF and cryogenics teams. Analysis showed that JT heat-exchanger effectiveness and temperature stratification in the two-phase and relief piping strongly influence the observed loads and helped isolate sources of excess heat. The campaign demonstrates that rigorous pre-test planning, real-time diagnostics, and automated reporting can improve both accuracy and efficiency, providing a template for future PIP-II cryomodule tests and for implementing targeted heat-load mitigations.

Porwisiak, D. [Fermilab; Wroclaw Tech. U.] (ORCID:↗

Computation of the expectation value of the spin operator S^ 2 for the spin-flip Bethe–Salpeter equation

Spin-flip (SF) methods applied to excited-state approaches like the Bethe–Salpeter equation allow access to the excitation energies of open-shell systems, such as molecules and defects in solids. The eigenstates of these solutions, however, are generally not eigenstates of the spin operator S^ 2 . Even for simple cases where the excitation vector is expected to be, for example, a triplet state, the value of S^ 2 may be found to differ from 2.00; this difference is called 'spin contamination'. The expectation values S^ 2 must be computed for each excitation vector, to assist with the characterization of the particular excitation and to determine the amount of spin contamination of the state. Here, our aim is to provide for the first time in the SF methods literature a comprehensive resource on the derivation of the formulas for S^ 2 as well as its computational implementation. After a brief discussion of the theory of the SF Bethe–Salpeter equation (BSE) and some examples further illustrating the need for calculating S^ 2 , we present the derivation for the general equation for computing S^ 2 with the eigenvectors from an SF-BSE calculation, how it is implemented in a Python script, and timing information on how this calculation scales with the size of the SF-BSE Hamiltonian.

75 CONDENSED MATTER PHYSICS, SUPERCONDUCTIVITY AND↗

MS2Planner: improved fragmentation spectra coverage in untargeted mass spectrometry by iterative optimized data acquisition

Motivation: Untargeted mass spectrometry experiments enable the profiling of metabolites in complex biological samples. The collected fragmentation spectra are the metabolite’s fingerprints that are used for molecule identification and discovery. Two main mass spectrometry strategies exist for the collection of fragmentation spectra: data-dependent acquisition (DDA) and data-independent acquisition (DIA). In the DIA strategy, all the metabolites ions in predefined mass-to-charge ratio ranges are co-isolated and co-fragmented, resulting in multiplexed fragmentation spectra that are challenging to annotate. In contrast, in the DDA strategy, fragmentation spectra are dynamically and specifically collected for the most abundant ions observed, causing redundancy and sub-optimal fragmentation spectra collection. Yet, DDA results in less multiplexed fragmentation spectra that can be readily annotated. Results: We introduce the MS2Planner workflow, an Iterative Optimized Data Acquisition strategy that optimizes the number of high-quality fragmentation spectra over multiple experimental acquisitions using topological sorting. Our results showed that MS2Planner increases the annotation rate by 38.6% and is 62.5% more sensitive and 9.4% more specific compared to DDA. Availability and implementation MS2Planner code is available at https://github.com/mohimanilab/MS2Planner. The generation of the inclusion list from MS2Planner was performed with python scripts available at https://github.com/lfnothias/IODA_MS.

47 OTHER INSTRUMENTATION↗

Divide and conquer: using RhizoVision Explorer to aggregate data from multiple root scans using image concatenation and statistical methods

Roots are important in agricultural and natural systems for determining plant productivity and soil carbon inputs. Sometimes, the amount of roots in a sample is too much to fit into a single scanned image, so the sample is divided among several scans, and there is no standard method to aggregate the data. Here, we describe and validate two methods for standardizing measurements across multiple scans: image concatenation and statistical aggregation. We developed a Python script that identifies which images belong to the same sample and returns a single, larger concatenated image. These concatenated images and the original images were processed with RhizoVision Explorer, a free and open-source software. An R script was developed, which identifies rows of data belonging to the same sample and applies correct statistical methods to return a single data row for each sample. These two methods were compared using example images from switchgrass, poplar, and various tree and ericaceous shrub species from a northern peatland and the Arctic. Most root measurements were nearly identical between the two methods except median diameter, which cannot be accurately computed by statistical aggregation. We believe the availability of these methods will be useful to the root biology community.

59 BASIC BIOLOGICAL SCIENCES↗

HPC Campaign Management: Remote data access with user-defined error bound using ADIOS and ZFP

Remote access to large-scale scientific datasets, like those generated by combustion simulations or other high-performance computing (HPC) applications, presents a significant challenge. Downloading entire datasets is often impractical due to their size and the bandwidth limitations of typical networks. To address this challenge, we propose a novel approach that enables efficient remote access to large datasets distributed across multiple facilities. Our method enables technologies to download only the data values of a select variable, in a select region of interest, to a user-defined accuracy. For this purpose, we extended the ADIOS IO library to provide read functions with user-defined accuracy, a remote data server that understands multidimensional selections of specific variables, steps and accuracy from an ADIOS dataset, and which uses lossy compression on the remote site to reduce the data to be transferred back to the client. In addition, our extension of the ADIOS library collects metadata from multiple datasets in small files called Campaign Archives, which can be shared among project participants on any HPC, cloud or laptop, and which can easily facilitate the discovery of content and pointers to the data location as well as remote access to the data by local tools as if data was local. This feature called Campaign Management, enables a group of scientists to manage related datasets stored in multiple files, across multiple facilities as if it was in a single file/database. We demonstrate the effectiveness of our approach using a 1.5 TB dataset from the S3D combustion simulation on Frontier at the Oak Ridge Leadership Facility. Even a single variable from this dataset, at 64 GB, is too large to be processed on a standard laptop. We show two different reading patterns for 2D plots and 3D visualization, with careful settings that a scientist studying combustion data would do and show that running the same Python scripts on Frontier directly takes comparable time than running them on the local laptop with remote access to the data on Frontier.

Podhorszki, Norbert [ORNL] (ORCID:000000019647542X↗

CheckV v0.0.1

CheckV is a command line python script which assesses the quality of viral genomes. It will be primarily (if not exclusively) used for academic applications and applied to viral genomes identified from environmental surveys.

Nayfach, Stephen↗

Lithium-Ion Battery Vent Gas Tools

The spreadsheets and Python scripts are used to determine vent gas hazard metrics (i.e. flammability limits, flame speed, etc.). These scripts and spreadsheets use open source literature to determine these hazard metrics. SAND2020-12540 O Sandia National Laboratories is a multimission laboratory managed and operated by National Technology & Engineering Solutions of Sandia, LLC, a wholly owned subsidiary of Honeywell International Inc., for the U.S. Department of Energy's National Nuclear Security Administration under contract DE-NA0003525.

Baird, Austin↗

ESS-DIVE File Level Metadata Extractor

The File-level Metadata (FLMD) parser is a lightweight python script that can produce a summary of fields based on column headers within a Comma-separated Values (CSV) file. The script enables a way to extract certain metadata fields from CSV data files. An optional configuration file can be used to select specific column headers to extract a smaller subset of values. The script can be used on a single file, or it can be given a directory to process groups of files in bulk. The FLMD parser outputs the metadata as a JSON and can be configured to updated the source file or produce an external companion file.

McNelis, Jack↗

Choppy Lite

The existing methodologies for gathering and computing zonal statistics from the combination of a raster image and a shapefile either require advanced programming knowledge in at least one language or the use of proprietary software such as ArcGIS. The software “Choppy Lite” offers several solutions for acquiring zonal statistics that can be used without proprietary software or programming knowledge. This software provides a Docker-based ecosystem, allowing users of any experience level to simply run a single line command in a terminal prompt independent of the operating system. Intermediate to advanced users can import the class provided by the software package into their own Python scripts.

Grant, JoshuaN.↗

MoorPy (Quasi-Static Mooring Analysis in Python)

MoorPy is a quasi-static mooring model and a suite of associated functions for mooring system analysis. The core model supports quasi-static analysis of moored floating systems including any arrangement of mooring lines and floating platforms. It solves the distributed position and tension of each mooring line segment using standard catenary equations. Floating platforms can be represented with linear hydrostatic characteristics. MoorPy automatically computes a floating system's equilibrium state and can be queried to identify a mooring system's nonlinear force-displacement relationships. Linearized stiffness matrices are efficiently computed using semi-analytic Jacobians. MoorPy also includes plotting functions and a library of mooring component property and cost coefficients. MoorPy can be used directly from Python scripts to perform mooring design and analysis tasks, or it can be coupled with other tools to compute quasi-static mooring reactions as part of a larger simulation.

Hall, Mathew↗

ccp137/SUGAR

This package (SUrface-wave Grader with ARtificial intelligence or SUGAR) automatically assigns a quality score to surface-wave seismograms (SAC format) using a trained artificial neural network model (included). Specifically, the python script 01_apply_ann.py calculates probability scores for a list of SAC files. You may consider seismograms with probability scores larger than 0.5 as acceptable data. Note no scores will be given to seismograms that do not pass an initial check (e.g., insufficient number of data points). See https://doi.org/10.1002/essoar.10507941.3 for more details.

Chai, Chengping [Oak Ridge National Lab. (ORNL), O↗