Search NASA⌕ Search

SEARCH · Search NASA

Results for “python code”

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

SU-E-T-29: A Web Application for GPU-Based Monte Carlo IMRT/VMAT QA with Delivered Dose Verification

Purpose: To enable an existing web application for GPU-based Monte Carlo (MC) 3D dosimetry quality assurance (QA) to compute “delivered dose” from linac logfile data. Methods: We added significant features to an IMRT/VMAT QA web application which is based on existing technologies (HTML5, Python, and Django). This tool interfaces with python, c-code libraries, and command line-based GPU applications to perform a MC-based IMRT/VMAT QA. The web app automates many complicated aspects of interfacing clinical DICOM and logfile data with cutting-edge GPU software to run a MC dose calculation. The resultant web app is powerful, easy to use, and is able to re-compute both plan dose (from DICOM data) and delivered dose (from logfile data). Both dynalog and trajectorylog file formats are supported. Users upload zipped DICOM RP, CT, and RD data and set the expected statistic uncertainty for the MC dose calculation. A 3D gamma index map, 3D dose distribution, gamma histogram, dosimetric statistics, and DVH curves are displayed to the user. Additional the user may upload the delivery logfile data from the linac to compute a 'delivered dose' calculation and corresponding gamma tests. A comprehensive PDF QA report summarizing the results can also be downloaded. Results: We successfully improved a web app for a GPU-based QA tool that consists of logfile parcing, fluence map generation, CT image processing, GPU based MC dose calculation, gamma index calculation, and DVH calculation. The result is an IMRT and VMAT QA tool that conducts an independent dose calculation for a given treatment plan and delivery log file. The system takes both DICOM data and logfile data to compute plan dose and delivered dose respectively. Conclusion: We sucessfully improved a GPU-based MC QA tool to allow for logfile dose calculation. The high efficiency and accessibility will greatly facilitate IMRT and VMAT QA.

07 ISOTOPE AND RADIATION SOURCES↗

PyMTensor 1.0.0

SAND2021-1654 O The Python Material Tensor code (PyMTensor) applies crystal symmetries to arbitrary material tensors. It uses symbolic algebra to exactly determine the zero tensor components and the relationships between the nonzero components for all crystallographic point groups. It is capable of computing components of higher-order material tensors needed when treating nonlinear effects. It has a simple and flexible interface for inputting tensor rank information and any known symmetries between tensor indices.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.

Jensen, DanielS↗

Nvd Search To Stix

This code is a python based application that queries the National Vulnerability Database (NVD) API search term and CPE endpoints. It then sifts through the API response and uses the STIX2 python package to create STIX SDOs, SROs, and SCOs from the applicable data. If there are CWEs associated with the bundle, it queries the OpenCVE API for information on the weakness, then translates that data to STIX as well. It then combines all the data into a STIX bundle and outputs it to a JSON file.

Beckman, BryanR [Idaho National Laboratory (INL), ↗

Binder-benchmarking

SAND2025-07593O Binder-benchmarking evaluates the speed and memory impacts of C++, Python, and Matlab code binders. As a repository, it provides a way to locally run computation-based and memory-based benchmark suites on pybind11 and nanobind-based code in a Docker image. The software runs simple-speed and memory benchmarks on primitive navigation and integration exemplar algorithms. 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.

Walker II, Michael [Sandia National Lab. (SNL-CA),↗

Study of MHD Stability, Active Mode Control, and Disruption Avoidance in NSTX-U

Learning how to achieve sustained operation at high plasma pressure is an important goal of the National Spherical Torus Upgrade (NSTX-U) program and is critically important to any future fusion power plant. This research addresses high priority stability and control issues outlined by the NSTX-U Program. Reduced models of the stabilization physics learned continue to be created and tested against actual plasma operation in NSTX, NSTX-U, and other tokamak devices. This research is forming physics-based models for disruption forecasting that aims to unify results across different fusion machines for more confident extrapolation of the techniques studied to future devices including ITER. The Disruption Event Characterization and Forecasting (DECAF) code was expanded to analyze data from the TCV tokamak, including real-time MHD analysis signals. The presence of a mode and likelihood of its m/n numbers can be tracked, as well as the mode frequency, although a limitation at low frequency does not yet allow tracking modes to the locking point in TCV. Initial analyses of NSTX-U operation were conducted using the DECAF code. The timing of sawtooth oscillations was investigated taking advantage of the more extensive L-mode operation of the device in its first run campaign. An initial investigation of thermal collapses in NSTX-U was also conducted with specific comparison to the Greenwald density limit. A local island power balance model to explain the density limit in tokamaks has been tested with NSTX data and is being evaluated as a potential disruption forecaster in the DECAF code, presently showing similarities to the global Greenwald density evolution and limit. A module was written for the DECAF code that generalizes magnetic spectrogram analysis of MHD modes. This new portable code, written in Python, discriminates the toroidal mode number of instabilities and can track each mode as a DECAF event, monitoring the evolution of the mode through bifurcation and locking points. This is a critical new capability to allow disruption event characterization for general tokamak databases.

70 PLASMA PHYSICS AND FUSION TECHNOLOGY↗

SMART Deliverable 6.1.2a: Application of the ORION tool to the IBDP Carbon Storage Site

Forecasting and managing potential induced seismic activity is one of the challenges facing commercialscale geologic carbon sequestration (GCS), as well as other geologic energy extraction and byproduct disposal technologies. Historically, the process to develop robust, science-based forecasts of induced seismicity has required an integrated effort from experts in seismology, geomechanics, and reservoir engineering to manage data, develop and evaluate models of subsurface processes, and to calibrate and interpret the results from a range of models to understand site behavior relative to prescribed standards and in the context of uncertainty in geologic characterization data, forecasting models, and operational scenario uncertainty. The Operational Forecasting of Induced Seismicity (ORION) toolkit is an open-source, observation-based forecasting toolkit that is being co-developed by two U.S. DOE-funded initiatives: the National Risk Assessment Partnership (NRAP) and the Scienceinformed Machine Learning for Accelerating Real Time Decisions in Subsurface Applications (SMART) Initiative. ORION is designed to provide functionality to support decision making about seismic hazard analysis and risk management for GCS stakeholders ranging from the public to site operators to expert seismologists. The tool, which is written as open-source code in the Python programming language, is composed of a desktop graphical user interface (GUI) and an underlying forecasting engine. The forecasting engine uses available reservoir properties, well and fluid injection scenario details, and observed seismic catalog data as inputs to produce a set of temporal and spatio-temporal seismic forecasts.

58 GEOSCIENCES↗

Computing the Instantaneous Collision Probability between Satellites using Characteristic Function Inversion

The probability that two satellites overlap in space at a specified instant of time is called their instantaneous collision probability. Assuming Gaussian uncertainties and spherical satellites, this probability is the integral of a Gaussian distribution over a sphere. This paper shows how to compute the probability using an established numerical procedure called characteristic function inversion. The collision probability in the short-term encounter scenario is also evaluated with this approach, where the instant at which the probability is computed is the time of closest approach between the objects. Python and R code is provided to evaluate the probability in practice. Overall, the approach has been established for over fifty years, is implemented in existing software, does not rely on analytical approximations, and can be used to evaluate two and three dimensional collision probabilities.

79 ASTRONOMY AND ASTROPHYSICS↗

classLog: Logistic regression for the classification of genetic sequences

Introduction Sequencing and phylogenetic classification have become a common task in human and animal diagnostic laboratories. It is routine to sequence pathogens to identify genetic variations of diagnostic significance and to use these data in realtime genomic contact tracing and surveillance. Under this paradigm, unprecedented volumes of data are generated that require rapid analysis to provide meaningful inference. Methods We present a machine learning logistic regression pipeline that can assign classifications to genetic sequence data. The pipeline implements an intuitive and customizable approach to developing a trained prediction model that runs in linear time complexity, generating accurate output rapidly, even with incomplete data. Our approach was benchmarked against porcine respiratory and reproductive syndrome virus (PRRSv) and swine H1 influenza A virus (IAV) datasets. Trained classifiers were tested against sequences and simulated datasets that artificially degraded sequence quality at 0, 10, 20, 30, and 40%. Results When applied to a poor-quality sequence data, the classifier achieved between >85% to 95% accuracy for the PRRSv and the swine H1 IAV HA dataset and this increased to near perfect accuracy when using the full dataset. The model also identifies amino acid positions used to determine genetic clade identity through a feature selection ranking within the model. These positions can be mapped onto a maximum-likelihood phylogenetic tree, allowing for the inference of clade defining mutations. Discussion Our approach is implemented as a python package with code available at https://github.com/flu-crew/classLog .

Zeller, Michael A.↗

Scanning ARM Precipitation Radar (SAPR) Velocity Azimuth Display (VAD)

The Velocity Azimuth Display (VAD, historical term) product contains retrievals of the zonal (north/south) and meridional (east/west) wind speed components, in precipitating systems, as a function of time and height. This product, which uses azimuthal variations in radial air velocity, allows quick insight into wind speed and wind direction in the vicinity of the radar when rainfall or snowfall is present. VAD data are derived from Corrected Moments in Antenna Coordinates Version 2 (CMAC2) using code within the Python ARM Radar Toolkit (Py-ART), an open-source architecture for interacting with radar data in the Python programming language.

54 ENVIRONMENTAL SCIENCES↗

Scanning ARM Precipitation Radar (SAPR) Quasi-Vertical Profile (QVP)

The Quasi-Vertical Profiles (QVP) VAP averages quality-controlled radar measurements along the axis of the azimuth. QVP allows quick insight into domain mean hydrometeor (e.g., snow, rain, melting layer) location and polarimetric data. QVP data are derived from Corrected Moments in Antenna Coordinates Version 2 (CMAC2) using code within the Python ARM Radar Toolkit (Py-ART), an open-source architecture for interacting with radar data in the Python programming language.

54 ENVIRONMENTAL SCIENCES↗

Heat Pump Retrofits for Central Plant Hydronic Heating Systems: A Software Toolkit for Screening and Design

Retrofitting existing central plants with high-efficiency heat pump technologies can play a crucial role in achieving long-term planning goals. Modern heat pump technologies are able to use waste heat recovery to meet a building's heating demand, but there is a lack of accessible tools designed for non-HVAC experts, such as building owners, to quickly and easily conduct what-if analysis, e.g., estimating retrofit costs and payback period for their partial or full equipment replacement. This paper introduces an open-source software toolkit designed to facilitate the initial screening and decision-making of heat pump retrofits in existing central plants using a building's yearly load profile from metered or utility bill data. The toolkit evaluates the technical and economic viability of replacing traditional central plant equipment with various options including water-to-water or air-to-water heat pumps, which can provide efficient and lower-cost heating and cooling. It allows users to compare current central plant configurations with retrofit scenarios, assessing energy consumption, life-cycle costs, and environmental impact. The toolkit offers (1) a web-based tool designed for user-friendly access by a broad audience and (2) Python-based source code for researchers and engineers conducting parametric studies and design parameter optimization. The toolkit compares a typical central plant configuration to a configuration that uses a heat pump to supply hydronic heating and cooling. The output metrics include energy consumption and output of each equipment, life-cycle cost analyses and metrics, and environmental impact of the system.

Excell, L↗

FOCUS: an alignment-free model to identify organisms in metagenomes using non-negative least squares

One of the major goals in metagenomics is to identify the organisms present in a microbial community from unannotated shotgun sequencing reads. Taxonomic profiling has valuable applications in biological and medical research, including disease diagnostics. Most currently available approaches do not scale well with increasing data volumes, which is important because both the number and lengths of the reads provided by sequencing platforms keep increasing. Here we introduce FOCUS, an agile composition based approach using non-negative least squares (NNLS) to report the organisms present in metagenomic samples and profile their abundances. FOCUS was tested with simulated and real metagenomes, and the results show that our approach accurately predicts the organisms present in microbial communities. FOCUS was implemented in Python. The source code and web-sever are freely available at http://edwards.sdsu.edu/FOCUS.

59 BASIC BIOLOGICAL SCIENCES↗

Integration of the Kromek D3S Detector and Spot Robot For Secondary Inspections

Inspecting vehicles and containers for the presence of nuclear material is a challenging task for border control and security. When performed manually by inspectors, this task also has an associated risk of exposing the inspectors to unknown radiation. With the advent of agile, easy-to-program, quadruped robots like the Boston Dynamics Spot, automation of secondary inspection can improve the efficiency of the inspection process and alleviates the radiation risks to inspectors. In this project, Brookhaven National Laboratory and the University of Massachussetts at Lowell explored how to automate a simple secondary inspection mission. The Spot robot comes with its own software development kit (SDK) that allows clients/users to write custom code in the Python programming language to control the robot. Spot also has a payload computer called Spot-CORE, which runs the Ubuntu Linux operating system and allows users to integrate external sensors, such as a radiation detector, with Spot. In this study, the Kromek D3S detector has been integrated with Spot via the Spot-CORE, allowing Spot to capture gamma spectra and neutron counts for a specified acquisition period. Two custom routines, search and confirmation, have been developed and executed in this specified order. The search routine directs Spot to go around the nearest obstacle, e.g., vehicle and container, in a preset distance and step to collect gamma and neutron gross counts with the D3S detector. The radiation data and the robot location corresponding to each step are stored and fed to the confirmation routine at the end of the search. The confirmation routine then navigates Spot to the locations of the highest gamma or neutron counts to perform a long, e.g., one minute, measurement, and gives the operators the signature gamma spectra and neutron counts at the hotspots. This paper presents a detailed description of this automated system along with results of the preliminary tests in identifying the location and signature of a 137Cs radiation source in a vehicle.

98 NUCLEAR DISARMAMENT, SAFEGUARDS, AND PHYSICAL P↗

JSPEC: A Program for IBS and Electron Cooling Simulation

JSPEC (JLab Simulation Package on Electron Cooling) is an open-source C++ program developed at Jefferson Lab to simulate the evolution of the ion beam under the intrabeam scattering effect and/or the electron cooling effect. JSPEC includes various models of the ion beam, the electron beam, and the friction force, aiming to reflect the latest advances in the field and to provide a useful tool to the community. JSPEC has been benchmarked against other cooling simulation codes and experimental data. It has been used to support the cooler design for JLEIC, an earlier JLab design for the Electron-Ion Collider. A Python wrapper of the C++ code, pyJSPEC, for Python 3.x environment has also been developed and released. It allows users to run JSPEC simulations in a Python environment and makes it possible for JSPEC to collaborate with other accelerator and beam modeling programs, as well as plentiful Python tools in data visualization, optimization, machine learning, etc. In this report, we introduce the features of JSPEC, with a focus on the latest development, and demonstrate how to use JSPEC and pyJSPEC with sample codes and numerical examples.

Accelerator Physics↗

NPTFit: A Code Package for Non-Poissonian Template Fitting

We present NPTFit, an open-source code package, written in Python and Cython, for performing non-Poissonian template fits (NPTFs). The NPTF is a recently developed statistical procedure for characterizing the contribution of unresolved point sources (PSs) to astrophysical data sets. The NPTF was first applied to Fermi gamma-ray data to provide evidence that the excess of ∼GeV gamma-rays observed in the inner regions of the Milky Way likely arises from a population of sub-threshold point sources, and the NPTF has since found additional applications studying sub-threshold extragalactic sources at high Galactic latitudes. The NPTF generalizes traditional astrophysical template fits to allow for the ability to search for populations of unresolved PSs that may follow a given spatial distribution. NPTFit builds upon the framework of the fluctuation analyses developed in X-ray astronomy, thus it likely has applications beyond those demonstrated with gamma-ray data. The NPTFit package utilizes novel computational methods to perform the NPTF efficiently. The code is available at http://github.com/bsafdi/NPTFit and up-to-date and extensive documentation may be found at http://nptfit.readthedocs.io.

79 ASTRONOMY AND ASTROPHYSICS↗

ACTINN: automated identification of cell types in single cell RNA sequencing

Abstract Motivation Cell type identification is one of the major goals in single cell RNA sequencing (scRNA-seq). Current methods for assigning cell types typically involve the use of unsupervised clustering, the identification of signature genes in each cluster, followed by a manual lookup of these genes in the literature and databases to assign cell types. However, there are several limitations associated with these approaches, such as unwanted sources of variation that influence clustering and a lack of canonical markers for certain cell types. Here, we present ACTINN (Automated Cell Type Identification using Neural Networks), which employs a neural network with three hidden layers, trains on datasets with predefined cell types and predicts cell types for other datasets based on the trained parameters. Results We trained the neural network on a mouse cell type atlas (Tabula Muris Atlas) and a human immune cell dataset, and used it to predict cell types for mouse leukocytes, human PBMCs and human T cell sub types. The results showed that our neural network is fast and accurate, and should therefore be a useful tool to complement existing scRNA-seq pipelines. Availability and implementation The codes and datasets are available at https://figshare.com/articles/ACTINN/8967116. Tutorial is available at https://github.com/mafeiyang/ACTINN. All codes are implemented in python. Supplementary information Supplementary data are available at Bioinformatics online.

Ma, Feiyang (ORCID:0000000262600787)↗

ThunderBoltz API

The ThunderBoltz application programming interface (API) code is written in Python and is comprised of a set of tools to facilitate compilation of the ThunderBoltz code, as well as fast assembly and formatting of input files for the ThunderBoltz code, post-processing tools of ThunderBoltz results, plotting tools, and runs/schedules the ThunderBoltz code executable for calculations. The ThunderBoltz API code is utilized for importing and manipulating input cross section sets, input conditions, and any other simulation settings made available within the ThunderBoltz input deck via user-defined settings or via automatic generation. The API comes with a set of plotting capabilities of input cross sections, results from ThunderBoltz, and post-processed results carried out with the API.

Park, Ryan↗