Search NASA⌕ Search

SEARCH · Search NASA

Results for “Python implementation”

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 271 records · Page 15

INL High Level Language Microcontroller Implementa

The overall goal of this project is to improve the security of embedded devices (microcontrollers) used in monitoring and control of energy-sector infrastructure. As these devices are essentially scaled-down personal computers (PCs), they are vulnerable to common low-level cyber-attacks such as buffer overflows and insecure authentication. The implementation of a modern high-level programming language on these microcontrollers would disallow such low-level attacks as the languages would have inherent safeguards against these types of cyber exploits. Idaho National Laboratory (INL) has partnered with Siemens Corporate Research (SCR) to develop and test a 4 th -generation language DNP3 implementation on real-world embedded hardware. These tests were carried out on control-system device models currently deployed in real-world applications. Testing was performed with existing C-based DNP implementation as well as the Python version developed by INL.

4GL↗

stochprop Documentation (Release 1.0)

Simulations of infrasonic propagation in the atmosphere typically utilize a single atmospheric specification describing the acoustic sound speed, ambient winds, and density as a function of altitude. Due to the dynamic and sparsely sampled nature of the atmosphere, there is a notable amount of uncertainty in the atmospheric state at a given location and time so that a more robust analysis of infrasonic propagation requires inclusion of this uncertainty. This Python library, stochprop, has been implemented using methods developed jointly by infrasound scientists at Los Alamos National Laboratory (LANL) and the University of Mississippi’s National Center for Physical Acoustics (NCPA). This software library includes methods to quantify variability in the atmospheric state, identify typical seasonal variability in the atmospheric state and generate suites of representative atmospheric states during a given season, as well as perform uncertainty analysis on a specified atmospheric state given some level of uncertainty. These methods have been designed to interface between propagation modeling capabilities such as InfraGA/GeoAc and NCPAprop and signal analysis methods in the LANL InfraPy tool.

58 GEOSCIENCES↗

Taylor wave solution for a general equation of state

This document describes a solution procedure for calculating the Taylor wave behind an unsupported Chapman–Jouguet (CJ) detonation in planar, cylindrical, and spherical geometries given a general equation of state. The resulting semi-analytic solution can be utilized to examine new equation of state models for detonation products and during the verification of hydrodynamic codes. The governing partial differential equations are reduced to ordinary differential equations in both characteristic and self-similar forms. The first-order systems corresponding to each geometry are amenable to solution numerically using commonly available methods. A difficulty arises at the CJ point in radial coordinates where the similarity equations become singular. Two separate strategies are proposed to integrate the first-order system. The first one uses an asymptotic approximation near the CJ point that can be used to perturb the boundary conditions. The second one applies a change of variables which removes the singularity at the expense of an additional equation to be integrated. A test problem is provided for the Davis products equation of state to illustrate the qualitative features of the Taylor wave in each geometric configuration and compared with a Lagrangian hydrodynamics research code. A Python code listing gives an implementation using the SciPy library to assists users in generating the results.

97 MATHEMATICS AND COMPUTING↗

Use of Digital Real-Time Simulation and Optimization to Identify Maximum Real Power Injection on Banshee Distribution Network

This study investigates the hosting capacity of the Banshee Distribution Network by optimizing the real power injection at carefully selected Distributed Energy Resource (DER) locations. The analysis is conducted within the framework of power system operational constraints, including bus voltage ranges, thermal line ratings, and transformer loading limits. A Python-based Genetic Algorithm (GA), implemented using the PyGAD library, is employed to iteratively identify the optimal power injection configuration that maximizes network utilization while preserving system reliability. The methodology integrates a real-time simulation environment using the Real-Time Digital Simulator (RTDS), allowing high-fidelity evaluation of power flow and voltage behavior under each proposed injection scenario. By coupling the optimization algorithm with real-time simulation feedback, this approach ensures that both static and dynamic constraints are enforced during the evaluation process. The GA leverages evolutionary operators such as selection, crossover, and mutation to navigate the nonlinear search space efficiently. The results of the study delineate the feasible hosting capacity at three targeted buses, reflecting maximum real power levels that can be injected without causing voltage violations, transformer overloading, or line congestion. These findings provide a decision- support tool for distribution planners and utilities aiming to integrate higher penetrations of DERs in existing infrastructure. Additionally, the work lays the foundation for extending such optimization techniques to multi-objective formulations, including economic dispatch and reactive power coordination, in future studies.

24 POWER TRANSMISSION AND DISTRIBUTION↗

Detecting Weak Spectral Lines in Interferometric Data through Matched Filtering

Modern radio interferometers enable observations of spectral lines with unprecedented spatial resolution and sensitivity. In spite of these technical advances, many lines of interest are still at best weakly detected and therefore necessitate detection and analysis techniques specialized for the low signal-to-noise ratio (S/N) regime. Matched filters can leverage knowledge of the source structure and kinematics to increase sensitivity of spectral line observations. Application of the filter in the native Fourier domain improves S/N while simultaneously avoiding the computational cost and ambiguities associated with imaging, making matched filtering a fast and robust method for weak spectral line detection. We demonstrate how an approximate matched filter can be constructed from a previously observed line or from a model of the source, and we show how this filter can be used to robustly infer a detection significance for weak spectral lines. When applied to ALMA Cycle 2 observations of CH{sub 3}OH in the protoplanetary disk around TW Hya, the technique yields a ≈53% S/N boost over aperture-based spectral extraction methods, and we show that an even higher boost will be achieved for observations at higher spatial resolution. A Python-based open-source implementation of this technique is available under the MIT license at http://github.com/AstroChem/VISIBLE.

79 ASTRONOMY AND ASTROPHYSICS↗

Identification of Stellar Flares Using Differential Evolution Template Optimization

In this paper, we explore methods for the identification of stellar flare events in irregularly sampled data of ground-based time domain surveys. In particular, we describe a new technique for identifying flaring stars, which we have implemented in a publicly available Python module called "PyVAN." The approach uses the Differential Evolution algorithm to optimize parameters of empirically derived light curve templates for different types of stars to fit a candidate light curve. The difference of the likelihoods that these best-fit templates produced the observed data is then used to delineate targets that are well-explained by a flare template but simultaneously poorly explained by templates of common contaminants. By testing on light curves of known identity and morphology, we show that our technique is capable of recovering flaring status in 69% of all light curves containing a flare event above thresholds drawn to include <1% of any contaminant population. By applying to Palomar Transient Factory data, we show consistency with prior samples of flaring stars, and identify a small selection of candidate flaring G-type stars for possible follow-up.

79 ASTRONOMY AND ASTROPHYSICS↗

An accurate and efficient algorithm for detection of radio bursts with an unknown dispersion measure, for single-dish telescopes and interferometers

Astronomical radio signals are subjected to phase dispersion while traveling through the interstellar medium. To optimally detect a short-duration signal within a frequency band, we have to precisely compensate for the unknown pulse dispersion, which is a computationally demanding task. We present the “fast dispersion measure transform” algorithm for optimal detection of such signals. Our algorithm has a low theoretical complexity of 2N{sub f}N{sub t}+N{sub t}N{sub Δ}log{sub 2}(N{sub f}), where N{sub f}, N{sub t}, and N{sub Δ} are the numbers of frequency bins, time bins, and dispersion measure bins, respectively. Unlike previously suggested fast algorithms, our algorithm conserves the sensitivity of brute-force dedispersion. Our tests indicate that this algorithm, running on a standard desktop computer and implemented in a high-level programming language, is already faster than the state-of-the-art dedispersion codes running on graphical processing units (GPUs). We also present a variant of the algorithm that can be efficiently implemented on GPUs. The latter algorithm’s computation and data-transport requirements are similar to those of a two-dimensional fast Fourier transform, indicating that incoherent dedispersion can now be considered a nonissue while planning future surveys. We further present a fast algorithm for sensitive detection of pulses shorter than the dispersive smearing limits of incoherent dedispersion. In typical cases, this algorithm is orders of magnitude faster than enumerating dispersion measures and coherently dedispersing by convolution. We analyze the computational complexity of pulsed signal searches by radio interferometers. We conclude that, using our suggested algorithms, maximally sensitive blind searches for dispersed pulses are feasible using existing facilities. We provide an implementation of these algorithms in Python and MATLAB.

79 ASTRONOMY AND ASTROPHYSICS↗

Robust Period Estimation Using Mutual Information for Multiband Light Curves in the Synoptic Survey Era

The Large Synoptic Survey Telescope (LSST) will produce an unprecedented amount of light curves using six optical bands. Robust and efficient methods that can aggregate data from multidimensional sparsely sampled time-series are needed. Here, we present a new method for light curve period estimation based on quadratic mutual information (QMI). The presented method does not assume a particular model for the light curve nor its underlying probability density and it is robust to non-Gaussian noise and outliers. By combining the QMI from several bands the true period can be estimated even when no single-band QMI yields the period. Period recovery performance as a function of average magnitude and sample size is measured using 30,000 synthetic multiband light curves of RR Lyrae and Cepheid variables generated by the LSST Operations and Catalog simulators. The results show that aggregating information from several bands is highly beneficial in LSST sparsely sampled time-series, obtaining an absolute increase in period recovery rate up to 50%. We also show that the QMI is more robust to noise and light curve length (sample size) than the multiband generalizations of the Lomb–Scargle and AoV periodograms, recovering the true period in 10%–30% more cases than its competitors. A python package with efficient Cython implementations of the QMI and other methods is provided.

79 ASTRONOMY AND ASTROPHYSICS↗

hls4ml: An Open-Source Codesign Workflow to Empower Scientific Low-Power Machine Learning Devices

Accessible machine learning algorithms, software, and diagnostic tools for energy-efficient devices and systems are extremely valuable across a broad range of application domains. In scientific domains, real-time near-sensor processing can drastically improve experimental design and accelerate scientific discoveries. To support domain scientists, we have developed hls4ml, an open-source software-hardware codesign workflow to interpret and translate machine learning algorithms for implementation with both FPGA and ASIC technologies. We expand on previous hls4ml work by extending capabilities and techniques towards low-power implementations and increased usability: new Python APIs, quantization-aware pruning, end-to-end FPGA workflows, long pipeline kernels for low power, and new device backends include an ASIC workflow. Taken together, these and continued efforts in hls4ml will arm a new generation of domain scientists with accessible, efficient, and powerful tools for machine-learning-accelerated discovery.

46 INSTRUMENTATION RELATED TO NUCLEAR SCIENCE AND ↗

Use of Digital Real-Time Simulation and Optimization to Identify Maximum Real Power Injection on the Banshee Distribution Network: Preprint

This study investigates the hosting capacity of the Banshee Distribution Network by optimizing the real power injection at carefully selected Distributed Energy Resource (DER) locations. The analysis is conducted within the framework of power system operational constraints, including bus voltage ranges, thermal line ratings, and transformer loading limits. A Python-based Genetic Algorithm (GA), implemented using the PyGAD library, is employed to iteratively identify the optimal power injection configuration that maximizes network utilization while preserving system reliability. The methodology integrates a real-time simulation environment using the Real-Time Digital Simulator (RTDS), allowing high-fidelity evaluation of power flow and voltage behavior under each proposed injection scenario. By coupling the optimization algorithm with real-time simulation feedback, this approach ensures that both static and dynamic constraints are enforced during the evaluation process. The GA leverages evolutionary operators such as selection, crossover, and mutation to navigate the nonlinear search space efficiently. The results of the study delineate the feasible hosting capacity at three targeted buses, reflecting maximum real power levels that can be injected without causing voltage violations, transformer overloading, or line congestion. These findings provide a decision- support tool for distribution planners and utilities aiming to integrate higher penetrations of DERs in existing infrastructure. Additionally, the work lays the foundation for extending such optimization techniques to multi-objective formulations, including economic dispatch and reactive power coordination, in future studies.

24 POWER TRANSMISSION AND DISTRIBUTION↗

Semi-analytic model of magnetized liner inertial fusion

The code that was developed is called SAMM (Semi-Analytic MagLIF Model). In 2015, McBride and Slutz published all of the equations that are solved by the code in the original SAMM paper: R. D. McBride and S. A. Slutz, ?A semi-analytic model of magnetized liner inertial fusion?, Phys. Plasmas 22, 052708 (2015); http://doi.org/10.1063/1.4918953. The SAMM code is now implemented in both the MATLAB and Python programming languages. Students from multiple universities have requested copies of the code so that they can become more familiar with the MagLIF concept. We would like to seek an open-source solution. There is no market value to this code, as there are plenty of more sophisticated simulation codes already available; SAMM is merely a simplified model that is purely for educational purposes. In fact, at least one graduate student (from the University of California, San Diego) has already implemented and published his own modified version of the model: J. Narkis, H. U. Rahman, J. C. Valenzuela, F. Conti, R. D. McBride, D. Venosa, and F. N. Beg, ?A semi-analytic model of gas-puff liner-on-target magneto-inertial fusion?, Phys. Plasmas 26, 032708 (2019); https://doi.org/10.1063/1.5086056. SAND2020-12244 M 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.

Moore, Thomas↗

DeepHyper: Asynchronous Hyperparameter Search for Deep Neural Networks

Hyperparameters employed by deep learning (DL) methods play a substantial role in the performance and reliability of these methods in practice. Unfortunately, finding performance-optimizing hyperparameter settings is a notoriously difficult task. Hyperparameter search methods typically have limited production-strength implementations or do not target scalability within a highly parallel machine, portability across different machines, experimental comparison between different methods, and tighter integration with workflow systems. In this paper, we present DeepHyper, a Python package that provides a common interface for the implementation and study of scalable hyperparameter search methods. It adopts the Balsam workflow system to hide the complexities of running large numbers of hyperparameter configurations in parallel on high-performance computing (HPC) systems. We implement and study asynchronous model-based search methods that consist of sampling a small number of input hyperparameter configurations and progressively fitting surrogate models over the input-output space until exhausting a user-defined budget of evaluations. We evaluate the efficacy of these methods relative to approaches such as random search, genetic algorithms, Bayesian optimization, and hyperband on DL benchmarks on CPU- and GPU-based HPC systems.

Balaprakash, Prasanna↗

Dynamic Contingency Analysis Tool

The Dynamic Contingency Analysis Tool (DCAT) is an open-platform and publicly available methodology to help develop applications that aim to improve the capabilities of power system planning engineers to assess the impact and likelihood of extreme contingencies and potential cascading events across their systems and interconnections. Outputs from the DCAT will help find mitigation solutions to reduce the risk of cascading outages in technically sound and effective ways. The current prototype DCAT implementation has been developed as a Python code that accesses the simulation functions of the Siemens PSS/E planning tool (PSS/E). It has the following features: It uses a hybrid dynamic and steady-state approach to simulating the cascading outage sequences that includes fast dynamic and slower steady-state events. It integrates dynamic models with protection scheme models for generation, transmission, and load. It models special protection systems (SPSs)/remedial action schemes (RASs) and automatic and manual corrective actions. Overall, the DCAT attempts to bridge multiple gaps in cascading-outage analysis in a single, unique prototype tool capable of automatically simulating and analyzing cascading sequences in real systems using multiprocessor computers. While the DCAT has been implemented using PSS/E in Phase I of the study, other commercial software packages with similar capabilities can be used within the DCAT framework.

Source record↗

ZERNIPAX: A fast and accurate Zernike polynomial calculator in Python

Zernike polynomials serve as an orthogonal basis on the unit disc, and have proven to be effective in optics simulations, astrophysics, and more recently in plasma simulations. Unlike Bessel functions, Zernike polynomials are inherently finite and smooth at the disc center (r=0), ensuring continuous differentiability along the axis. This property makes them particularly suitable for simulations, requiring no additional handling at the origin. We developed ZERNIPAX, an open-source Python package capable of utilizing CPU/GPUs, leveraging Google's JAX package and available on GitHub as well as the Python software repository PyPI. Furthermore, our implementation of the recursion relation between Jacobi polynomials significantly improves computation time compared to alternative methods by use of parallel computing while still performing more accurately for high-mode numbers.

Astrophysics↗

CHIANTI-AN ATOMIC DATABASE FOR EMISSION LINES. XII. VERSION 7 OF THE DATABASE

The CHIANTI spectral code consists of an atomic database and a suite of computer programs to calculate the optically thin spectrum of astrophysical objects and carry out spectroscopic plasma diagnostics. The database includes atomic energy levels, wavelengths, radiative transition probabilities, collision excitation rate coefficients, and ionization and recombination rate coefficients, as well as data to calculate free-free, free-bound, and two-photon continuum emission. Version 7 has been released, which includes several new ions, significant updates to existing ions, as well as Chianti-Py, the implementation of CHIANTI software in the Python programming language. All data and programs are freely available at http://www.chiantidatabase.org, while the Python interface to CHIANTI can be found at http://chiantipy.sourceforge.net.

79 ASTRONOMY AND ASTROPHYSICS↗

Fast and flexible neutrino decoupling. Part I. The Standard Model

Cosmological determinations of the number of relativistic neutrino species, N eff , are becoming increasingly accurate, and further improvements are expected both from CMB and BBN data. Given this context, we update the evaluation of N eff and the current entropy density via the momentum-averaged approach. This allows for a numerically fast description of neutrino decoupling, easily portable to an array of new physics scenarios. We revisit all aspects of this approach, including collision terms with full electron mass dependence, finite temperature QED corrections to the equation of state, neutrino oscillations, and the modelling of neutrino ensembles with effective chemical potentials. For integrated observables, our results differ by less than 0.04% from the solution of the momentum-dependent evolution equation. We outline how to extend the approach to BSM settings, and will highlight its power in Part II. To facilitate the practical implementation, we release a Mathematica and python code within nudec_BSM_v2, easily linkable to BBN codes.

72 PHYSICS OF ELEMENTARY PARTICLES AND FIELDS↗

Color Transformations of Photometric Measurements of Galaxies in Optical and Near-infrared Wide-field Imaging Surveys*

Abstract Over the past 2 decades, wide-field photometric surveys in optical and infrared domains reached a nearly all-sky coverage thanks to numerous observational facilities operating in both hemispheres. However, subtle differences among exact realizations of Johnson and SDSS photometric systems require one to convert photometric measurements into the same system prior to analysis of composite data sets originating from multiple surveys. It turns out that the published photometric transformations lead to substantial biases when applied to integrated photometry of galaxies from the corresponding catalogs. Here we present photometric transformations based on piece-wise linear approximations of integrated photometry of galaxies in the optical surveys SDSS, DECaLS, BASS, MzLS, DES, DELVE, KiDS, VST ATLAS, and the near-infrared surveys UKIDSS, UHS, VHS, and VIKING. We validate our transformations by constructing k -corrected color–magnitude diagrams of non-active galaxies and measuring the position and tightness of the “red sequence.” We also provide transformations for aperture magnitudes and show how they are affected by the image quality difference among the surveys. We present the implementation of the derived transformations in python and idl and also a web-based color transformation calculator for galaxies. By comparing DECaLS and DES, we identified systematic issues in DECaLS photometry for extended galaxies, which we attribute to the photometric software package used by DECaLS. As an application of our method, we compiled two multi-wavelength photometric catalogs for over 200,000 low- and intermediate-redshift galaxies originating from CfA FAST and Hectospec spectral archives.

Astronomy & Astrophysics↗