Search NASASearch

SEARCH · Search NASA

Results for “Python Programming”

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 109 records · Page 6

Machine Learning-Based Predictive Analytics for Aircraft Engine Conceptual Design

Big data and artificial intelligence/machine learning are transforming the global business environment. Data is now the most valuable asset for enterprises in every industry. Companies are using data-driven insights for competitive advantage. With that, the adoption of machine learning-based data analytics is rapidly taking hold across various industries, producing autonomous systems that support human decision-making. This work explored the application of machine learning to aircraft engine conceptual design. Supervised machine-learning algorithms for regression and classification were employed to study patterns in an existing, open-source database of production and research turbofan engines, and resulting in predictive analytics for use in predicting performance of new turbofan designs. Specifically, the author developed machine learning-based analytics to predict cruise thrust specific fuel consumption (TSFC) and core sizes of high-efficiency turbofan engines, using engine design parameters as the input. The predictive analytics were trained and deployed in Keras, an open-source neural networks application program interface (API) written in Python, with Google’s TensorFlow (an open source library for numerical computation) serving as the backend engine. The promising results of the predictive analytics show that machine-learning techniques merit further exploration for application in aircraft engine conceptual design.

deep-learning

Radiation Data Portal: Connection of Radiation Measurements on Airplane Flights with Observations of Solar-Terrestrial Environment

The impact of solar radiation dramatically increases at high altitudes in the Earth’s atmosphere and in space. Therefore, continuous monitoring of the radiation environment is critical for the safety of aircraft and spacecraft crews and passengers. Addressing the problem requires a complex approach of integration of different data sources and enhancement of the visualization and search capabilities. The Radiation Portal Database represents an interactive web-based application for convenient search and visualization of in-flight radiation measurements and exploration of various properties related to the radiation environment. The primary element of the Radiation Portal back-end is a MySQL relational database that currently contains the radiation measurements obtained from the Automated Radiation Measurements for Aerospace Safety (ARMAS)device, and soft X-ray and proton fluxes from Geostationary Orbiting Environmental Satellite (GOES). The developed Application Programming Interface (API) and related Python routines allow a user to retrieve the database records directly and efficiently, without interaction with the web interface. As a use case of the Radiation Portal, we examine the properties of the ARMAS flights taken during the enhanced Solar Proton (SP) fluxes and compare them to the flights of similar time and location taken during SP-quiet periods.

SMD

Air Traffic Management TestBed: Non-Java Programming Language Support

The Air Traffic Management (ATM) TestBed provides a simple and easy capability to connect high-fidelity simulations for supporting National Aeronautics and Space Administration (NASA) and community research. Simulation components are connected to the TestBed via plugin adapters which can be publishers, subscribers, or both. Though the plugin adapters are written in Java programming language, connectivity between TestBed and non-Java applications are supported. This document describes procedures to access the TestBed data exchange messages using external applications such as MATLAB and web browsers, as well as non-Java programming language such as C, Python, and JavaScript. Example simulation layouts are presented. Step-by-step instructions to run adapters, and to connect to the external tools are also provided.

Chok Fung Lai

CHIANTI-An Atomic Database for Emission Lines. XV. Version 9, Improvements for the X-Ray Satellite Lines

CHIANTI contains a large quantity of atomic data for the analysis of astrophysical spectra. Programs are available in IDL and Python to perform calculation of the expected emergent spectrum from these sources. The database includes atomic energy levels, wavelengths, radiative transition probabilities, rate coefficients for collisional excitation, ionization, and recombination, as well as data to calculate free–free, free–bound, and two-photon continuum emission. In Version 9, we improve the modeling of the satellite lines at X-ray wavelengths by explicitly including autoionization and dielectronic recombination processes in the calculation of level populations for select members of the lithium isoelectronic sequence and Fe XVIII–XXIII. In addition, existing data sets are updated, new ions are added, and new total recombination rates for several Fe ions are included. All data and IDL programs are freely available at http://www.chiantidatabase.org or through SolarSoft, and the Python code ChiantiPy is also freely available at https://github.com/chianti-atomic/ChiantiPy.

X-rays (general)

Abstract - Belbas, Nicholas (EC2)

Originally, I was brought into the Design and Analysis Branch in the Crew and Thermal Systems to work on administrative tasks like archiving and scheduling. However, I ended up splitting my time between secretarial tasks and a technical project. My technical project was originally meant to be a wireless sensor package for the 20ft Spacecraft Thermal Vacuum Chamber in the B7 High Bay. I would be using a miniature wifi development board and a temperature/humidity sensor along with custom 3D modeling to accomplish this. However, after some discussion with my technical mentor, the plan was changed to a mobile autonomous self-charging sensor platform. A mobile platform will allow the sensors to be moved around without depressurizing the chamber. Also, the self-charging aspect of the package allows for almost unlimited time in the chamber. If the on-board battery runs low, the robot can easily be driven to its charging dock and continue to transmit while charging. The driving base is based around a Raspberry Pi 3 board with a 12C PMW DC Motor controller and a PWM controller driving two small gear motors. The sensor transmitter itself is a RHT03 temperature and humidity sensor and Cozir CO2 sensor connected to an ESP8266 Huzzah board. The power distribution system utilizes a pair of 3.7v 3600mah lipo batteries wired to Powerboost 500 boards. Also, the self-charging mechanism utilizes two 12v-max inductive charging coils wired into the same Powerboost boards as the battery. The Raspberry pi is running Python 3.3 for the driving base and Javascript MJPEG library for transmitting live video from the onboard camera. The sensor package is running Arduino-based C++ and the program capturing the data is running PyqtGraph Python and HTML. The shell of the robot itself is a 3D printed case that will (work in progress) snap together. The photo to the left shows the two halves separated from each other. The black shell contains the power distribution boards and connectors while the white shell contains the driving base and data systems.

Belbas, Nicholas

Validation and Verification of Python based Neutron Spectrum Unfolding Software

To validate and verify the python-based code (PySL), designed to replicate the programs used by STAYSL for Beam Correction Factor (BCF) and Self-Shielding Factor (SHIELD), a series of tests were performed. To test BCF a python script was written to generate a random flux history file and both versions of the code processed the data. The test verified matching values up to at least one decimal place, approximately 10,000 tests where run and each one passed. Isotopes began to fail the tests once neutron saturation was reached. To verify this the total time of exposure was varied the isotopes that failed were compared to a list of their half-lives. The test process for SHIELD was very similar but, in this case, the code began by producing an input file with varying thickness and device type/environment for the SHIELD input. The failure condition for this test was if any of the data points for an isotope had a difference above 3%. Approximately 40 of these tests were run and there were only 3 isotopes that had reoccurring failures but only 2% of their points were above the 3% difference. A visual comparison was conducted by plotting the results from both programs. Although the test failed, the differences between their values were minuscule, and the self-shielding factor’s shape was preserved when plotted. Next steps for this project will be validating and verifying the python-based SigPhi code and then reproducing and testing the least squares unfolding performed by STAYSL.

73 - NUCLEAR PHYSICS AND RADIATION PHYSICS

CG-Kit: Code Generation Toolkit for performant and maintainable variants of source code applied to Flash-X hydrodynamics simulations

CG-Kit is a new Code Generation tool-Kit that we have developed as a part of the solution for portability and maintainability for multiphysics computing applications. The development of CG-Kit is rooted in the urgent need created by the shifting landscape of high-performance computing platforms and the algorithmic complexities of a particular large-scale multiphysics application: Flash-X. To efficiently use computing resources on a heterogeneous node, an application must have a map of computation to resources and a mechanism to move the data and computation to the resources according to the map. Most existing performance portability solutions are focussed on abstracting the expression of computations so that a unified source code can be specialized to run on different resources. However, such an approach is insufficient for a code like Flash-X, which has a multitude of code components that can be assembled in various permutations and combinations to form different instances of applications. Similar challenges apply to any code that has composability, where a single specified way of apportioning work among devices may not be optimal. Additionally, use cases arise where the optimal control flow of computation may differ for different devices while the underlying numerics remain identical. This combination leads to unique challenges including handling an existing large code base in Fortran and/or C/C++, subdivision of code into a great variety of units supporting a wide range of physics and numerical methods, different parallelization techniques for distributed and shared memory systems and accelerator devices, and heterogeneity of computing platforms requiring coexisting variants of parallel algorithms. All of these challenges demand that scientific software developers apply existing knowledge about domain applications, algorithms, and computing platforms to determine custom abstractions and granularity for code generation. There is a critical lack of tools to tackle those problems. CG-Kit is designed to fill this gap by providing a user with the ability to express their desired control flow and computation-to-resource map in the form a pseudocode-like recipe. It consists of standalone tools that can be combined into highly specific and, we argue, highly effective portability and maintainability toolchains. Here we present the design of our new tools: parametrized source trees, control flow graphs, and recipes. The tools are implemented in Python. They are agnostic to the programming language of the source code targeted for code generation. In conclusion, we demonstrate the capabilities of the toolkit with two examples, first, multithreaded variants of the basic AXPY operation, and second, variants of parallel algorithms within a hydrodynamics solver, called Spark, from Flash-X that operates on block-structured adaptive meshes.

Algorithmic portability

Evapotranspiration partitioning estimates from 8 methods from 47 NEON sites, 2019-2021

This dataset provides daily estimates of evapotranspiration (ET) and the transpiration-to-evapotranspiration ratio (T/ET) across 47 terrestrial National Ecological Observatory Network (NEON) sites spanning diverse environmental and biome conditions in the United States across three years of data (2019-2021). Daily ET is reported in both energy units (MJ m⁻² day⁻¹) and equivalent water depth (mm day⁻¹), assuming a constant latent heat of vaporization of 2.45 MJ/kg. The primary method uses a hybrid recurrent neural network–Penman–Monteith framework (RNN-PM), which integrates physically based surface energy balance constraints with data-driven learning to partition ET into transpiration and evaporation components. Model inputs include in situ meteorological observations (air temperature, vapor pressure deficit, wind speed, and radiation) combined with satellite-derived land surface temperature, leaf area index, and soil moisture. For benchmarking and uncertainty assessment, T/ET estimates from seven additional models are included: Priestley-Taylor Jet Propulsion Laboratory (PT-JPL), Penman-Monteith (P-M), Two-Source Energy Balance (TSEB), Support Vector Regression (SVR), and Categorical Boosting (CatBoost), among others—spanning empirical, machine-learning, and process-based approaches (see methods section or linked publication for detailed descriptions). Data Package Contents: The dataset a csv files containing daily ET and T/ET estimates for each site and model, along with associated metadata files these variables. Data can be accessed using common spreadsheet software (e.g., Microsoft Excel, LibreOffice) or programming environments such as R or Python. Together, these data support cross-site comparisons of ecosystem water use, evaluation of ET partitioning methods, and development of improved land–atmosphere exchange models.

EARTH SCIENCE > ATMOSPHERE

Bridging the Last Mile with Open-Source Advancements: Empowering Communities through Fusion of Aerosol Optical Depth (AOD) Products from Multi-Satellite Sensors

Aerosol Optical Depth (AOD) is a crucial parameter for understanding atmospheric aerosol distribution and their impact on climate and air quality. With the growing number of Earth observation satellites, there is an abundance of AOD products derived from various sensors onboard both geostationary and low-orbit satellites. The availability of multiple datasets provides an opportunity to harness the strengths of each sensor and create comprehensive and accurate AOD datasets for climate and air quality studies at different temporal and spatial scales. Our NASA aerosol MEaSURES project has made significant strides in recent years by undertaking the ambitious task of developing an open-source package tailored for fusing AOD products from different sources. The package is based on OOP (Object-Oriented Programming) design and is implemented in Python modules. Generic interfaces enable easy inclusion of large and heterogeneous data. The package may be utilized to produce harmonized AOD datasets with enhanced spatial and temporal coverage. The latest version of the package is able to process and integrate the dark-target AOD data from six different sensors: AHI Himawari-8, ABI GOES-West, ABI GOES-East, MODIS AQUA, MODIS TERRA, and VIIRS SNPP. Rigorous validation and intercomparison studies have been performed to assess the accuracy and reliability of the fused AOD product against ground-based measurements and reference datasets. The open-source nature of the developed package ensures transparency, reproducibility, and community engagement. The research community and stakeholders can access, contribute to, and further improve the fusion methodology, making it adaptable to other studies, or expanding it to include new satellite data as they become available. In this poster presentation, we will introduce the accomplishments and challenges faced during the development of the open-source package for AOD data fusion, and demonstrate the advantages of combining AOD products from the six aforementioned satellite sensors. The presentation aims to foster discussions, collaborations, and future directions in integrating Earth observation and remote sensing data, which may contribute to a better understanding of atmospheric aerosols and their impacts on our environment.

Zhaohui Zhang

"Source Term Modeling for Advanced Gas Micro-Reactors"

Maintaining the safety of the public, environment, and operating personnel is the most important factor in designing, operating, maintaining, and decommissioning nuclear reactors. In recent years, there has been a growing interest in the development of micro-reactors employing TRi-structural ISOtropic (TRISO)-coated particle fuel. In gas reactors, TRISO fuel plays an important role in the safety case for high temperature reactors because of the fission product retention properties of the fuel. This ability enables the use of a functional containment strategy for the reactor where multiple barriers are used to prevent fission product release to the environment. Part of the safety analysis of these advanced reactors is the assessment of radionuclide releases under normal and accident conditions through the multiple credited safety barriers. Using conservative assumptions, a mechanistic analysis can be performed to quantify these releases that combines the probabilistic assessment of failure with analytic solutions to radionuclide transport equations. Source term modeling for TRISO fuel has been performed for previous reactor designs; however, these models are outdated, in many cases proprietary, and need updates to be applied to the current state of TRISO fuel technology and alternative gas reactor core configurations [1]. Currently, the only publicly available source term assessment for gas reactors is an expert-based Monte Carlo simulation based on the effectiveness of the fuel kernel, coating layers, and graphite block in a modular high temperature gas reactor [2]. Thus, there is a need to develop a simple, versatile, and mechanistic model of fission product release and transport in gas reactor cores that could be applied to a variety of reactors through user inputs and reactor-specific radionuclide inventories. The release is calculated by the diffusion of the key safety important fission products through the kernel, silicon carbide (SiC), graphite for both intact and defective TRISO particles based on fuel and graphite temperatures in the reactor under normal operation. These releases from the fuel enter the coolant where they can plate-out on cooler surfaces. A clean-up model is included for designs with a coolant purification system to remove fission gases. This initial distribution of fission products in the reactor serves as an initial condition for potential releases under postulated accident conditions. The model then can calculate the fission product release for any transient temperature profile and fission product releases can then be used to assess radiological dose to the workers and the public using conventional dose tools. Data on the diffusion of fission products is based on historic German TRISO experiments and the more current Department of Energy (DOE) Advanced Gas Reactor (AGR) TRISO fuel development program. The model is coded in python with inputs and outputs in excel spreadsheets, as well as python plotting utilities to aid in the interpretation of the results. References: [1] INL, NGNP Mechanistic Source Term White Paper, INL-10-17997, July 2010. [2] David A. Petti, Richard R. Hobbins, Peter Lowry, Hans Gougar, “Representative Source Terms and The Influence of Reactor Attributes on Functional Containment in Modular High Temperature Gas-cooled Reactors,” Nuclear Technology, Vol. 184, p. 181-197, Nov. 2013.

07 ISOTOPE AND RADIATION SOURCES

Cross Section Evaluation for Exclusive Channels of K+Λ and K+Σ0 Electroproduction off Protons Using CLAS Detector Data

In this work, a method for evaluating the cross sections of electroproduction of K+Λ0 and K+Σ0 off protons in the region of invariant masses of final hadrons MK + MY <W < 2.65 GeV (MK and MY being the masses of the kaon and hyperon, respectively) and squares of four-momentum transfers of virtual photons, i.e., photon virtualities 0 < Q2 < 5 GeV2, is developed based on experimental data of these exclusive channels’ cross sections measured by the CLAS detector in Hall B at Jefferson Lab. A set of algorithms has been implemented to evaluate the differential cross sections of these channels, along with their statistical and systematic uncertainties. A program was developed for the evaluation of differential cross sections and structure functions using C++ and Python libraries. An interactive website was created for working with the program, enabling the analysis of one-dimensional and two-dimensional dependences of structure functions and differential cross sections. The evaluation of differential cross sections for the K+Λ and K+Σ0 electroproduction channels is necessary for extracting the structure function σLT from the data on the polarization asymmetry of electroproduction reactions of these final states with longitudinally polarized electrons. The obtained results are also important for the development of realistic Monte Carlo event generators in planning future experiments and for evaluating the efficiency of detecting final particles when extracting reaction cross sections from experimental data.

Golda, A. V.

BLDAP Intro to Python/Data Science Curriculum v1

The Github repository contains the Jupyter notebooks for the intro to Python / Data Science course for Berkeley Lab Director's Apprenticeship Program (BLDAP). This course is designed for students with little to no experience in coding to learn skills in Python necessary for data science. Students utilize Jupyter notebooks throughout the course. The overall goal is for students to learn how to use Python to clean, analyze, and visualize large data sets in order to communicate effectively their conclusions about the data set. Students apply the skills they learned on actual data sets provided by researchers in Berkeley Lab.

Hales, Laurel [Lawrence Berkeley National Laborato

Connecting Users and Applications with Po.daac Hosted GHRSST Data

The 80+ GHRSST public datasets represent a rich resource for sea surface temperature research and applications given their time series length, resolution, spatial coverage, varying measurement types and processing levels, and availability in the full spectrum of PO.DAAC tools and services ecosystem. The PO.DAAC has created a publicly accessible recipe suite for the user community to perform straightforward yet powerful computations on GHRSST data using python recipes, Jupyter notebooks, R, Matlab, and the NCO programming language. These recipes include numerical computations for regional and global SST trends, anomaly derivations, EOF analysis, climate signal reproduction, and ocean phenology. For example, one recipe reproduces a famous SST based warming figure from the Fourth National Climate Assessment (USA) while another focuses on quantifying the regional changes in ocean SST phenology. Most are python-based while some contain hybrid calls and leverage the NCO programming interface too. All are available on the PO.DAAC user forum (https://podaac.jpl.nasa.gov/forum/) and/or via the open source NASA GitHub repository (https://github.com/nasa/podaac_tools_and_services). Several are available in the Jupyter notebook framework including podaacypy (https://github.com/nasa/podaacpy), a recipe for GHRSST granule metadata discovery and application, and more recently a Jupyter notebook developed to support data analysis and visualization of a cloud-based Zarr formatted Level 4 MUR dataset in the AWS Open Data Registry. Throughout the summer of 2020, the PO.DAAC intends to add and migrate more of its numerical recipes to the Jupyter notebook framework and publish them on its open source GitHub repository.

Gentemann, Chelle

Python & Qt, Powerful Tools for Technical Computing

The objective of this presentation is to give a brief overview of Python computer language and Qt for Python which provides an interface to Python for building graphical applications. The Qt language provides a method for rapid programming of Graphical User Interfaces (GUIs) that are highly scalable, robust and platform independent. Both Python and Qt provide a powerful set of tools for Dynamic Analysis which are based on Open-Source software. Many problems and calculations in Structural Dynamics such as Power Spectral Density, Shock Response Spectrum and Vibration Response Spectrum can be easily calculated using these tools. The advantage of using Open-Source software is the ability to create custom graphical user interfaces similar to Matlab without the expense of software licensing and the ability to customize the software to an organization's specific needs. Also, another advantage is the ability to know which algorithms are being used by the GUI, know the numerical limitations and scale to large size data sets. I will end the presentation by demonstrating a Structural Dynamics GUI I created that was designed primarily to interactively analyze Post Flight high speed data provided by the ground station telemetry networks.

Grillo, Vincent

Computerized Assignment of Reviewers to Applicants for the Truman Fellowship

This report presents a user-friendly tool for assigning reviewers to the President Harry S. Truman Postdoctoral Fellowship applicants, replacing a previous program that required technical skills. Built with Python libraries, it organizes reviewer preferences and balances workloads, outputting five solutions as Excel files. Validation confirms its effectiveness, making it suitable for broader applications while ensuring efficient assignments without technical expertise.

97 MATHEMATICS AND COMPUTING

Tough Errors Are no Match (TEAM): Optimizing the quantum compiler for noise resilience

This report summarizes Unitary Fund’s contributions to the Department of Energy’s TEAM project (DE-SC0020266) under Thrust 2: Quantum Programming and Compilation. The central outcomes of this work have been the development of Mitiq, an open-source Python toolkit for applying quantum error mitigation (QEM) techniques to noisy quantum programs, and the invention, benchmarking and theoretical investigation of novel QEM techniques. Additional outcomes include the development of other open source software packages for the usage, simulation and control of quantum computers.

97 MATHEMATICS AND COMPUTING

Mojo: MLIR-based Performance-Portable HPC Science Kernels on GPUs for the Python Ecosystem

We explore the performance and portability of the novel Mojo language for scientific computing workloads on GPUs. As the first language based on the LLVM’s Multi-Level Intermediate Representation (MLIR) compiler infrastructure, Mojo aims to close performance and productivity gaps by combining Python’s interoperability and CUDA-like syntax for compile-time portable GPU programming. We target four scientific workloads: a seven-point stencil (memory-bound), BabelStream (memory-bound), miniBUDE (compute-bound), and Hartree–Fock (compute-bound with atomic operations); and compare their performance against vendor baselines on NVIDIA H100 and AMD MI300A GPUs. We show that Mojo’s performance is competitive with CUDA and HIP for memory-bound kernels, whereas gaps exist on AMD GPUs for atomic operations and for fast-math compute-bound kernels on both AMD and NVIDIA GPUs. Although the learning curve and programming requirements are still fairly low-level, Mojo can close significant gaps in the fragmented Python ecosystem in the convergence of scientific computing and AI.

Godoy, William [ORNL] (ORCID:0000000225905178)

Using Parameter Sweep in WaterTAP to Analyze New Water Treatment Technologies

We describe a powerful and generalized parameter sweep tool in this report that was originally developed to analyze the performance of existing and novel water treatment models being developed in WaterTAP. Since WaterTAP is built upon IDAES and Pyomo, the parameter sweep tool can be used to systematically explore and debug the behavior of most Pyomo and IDAES numerical models. In order to enable meaningful analyses, the parameter sweep tool has been designed with the following features: 1) Model flexibility: The parameter sweep tool does not enforce any restrictions on the types of models that can be used with it. As long as a Pyomo model can be solved and the parameter is active and mutable, the tool only needs functions that describe how to run the model, the sweep parameters, and the output quantities of interest. 2) Flexible sampling: The parameter sweep tool has inbuilt functions to generate samples from a random distribution or a multidimensional Euclidean space. Furthermore, the users have to ability to supply samples generated from a tool of their choice. 3) Multiple sweep types: A user can choose from one of 3 types of parameter sweeps depending on their needs. 4) Detailed outputs: Outputs generated by the parameter sweep tool can be stored in detailed H5 file or user-friendly CSV files for post processing. 5) Parallel computing: The parameter sweep supports shared and distributed memory parallel computing to enable the use of high performance computers (HPC) for large-scale analyses. 6) Modular: The parameter sweep tool is self-contained and can easily be integrated within an outer-loop analysis or as desired by the user. 7) Ease of use: The tool is well documented and a simple sweep can be easily executed by following the online documentation in a few lines of code. We demonstrate the use of the parameter sweep tool on a simple water treatment system from the WaterTAP repository and show its parallel scaling performance on an Apple laptop and NREL's Eagle HPC. The parameter sweep tool is actively being used with models currently being developed within WaterTAP and we expect its use to grow beyond it to other IDAES and Pyomo models.

97 MATHEMATICS AND COMPUTING