Search NASASearch

SEARCH · Search NASA

Results for “Python”

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

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

At least 91 records · Page 5

wmpy-power: A Python package for process-based regional hydropower simulation

Hydropower is an important source of renewable energy in many parts of the world. The generation potential for a hydropower facility can vary greatly due to fluctuations in precipitation and snowmelt patterns impacting streamflow and reservoir storage. Human activities such as irrigation, manufacturing, and hydration can also influence water availability at nearby and downstream facilities. wmpy-power--the hydropower model described in this work--is process-based, leveraging explicit reservoir storage and release data to address impacts on hydropower from climate change and human adaptive behaviors to inform long-term planning and resource-adequacy considerations.

13 HYDRO ENERGY

DeepHyper: A Python Package for Massively Parallel Hyperparameter Optimization in Machine Learning

Machine learning models are increasingly applied across scientific disciplines, yet their effectiveness often hinges on heuristic decisions—such as data transformations, training strategies, and model architectures—that are not learned by the models themselves. Automating the selection of these heuristics and analyzing their sensitivity is crucial for building robust and efficient learning workflows. DeepHyper addresses this challenge by democratizing hyperparameter optimization, providing accessible tools to streamline and enhance machine learning workflows from a laptop to the largest supercomputer in the world. Building on top of hyperparameter optimization, it unlocks new capabilities around ensembles of models for improved accuracy and uncertainty quantification. All of these organized around efficient parallel computing.

ensemble

SSAPy - Space Situational Awareness for Python

SSAPy is a fast and flexible orbit modeling and analysis tool for orbits spanning from low-Earth into the cislunar regime. Orbits can be flexibly specified from common input formats such as Keplerian elements or two-line element (TLE) data files. SSAPy allows users to model satellites and specify parameters such as satellite area, mass, and drag coefficients. SSAPy includes a customizable force-propagation with a range of Earth, Lunar, radiation, atmospheric, and maneuvering models. SSAPy makes use of various community integration methods and can calculate time-evolved orbital quantities, including satellite magnitudes and state vectors. Users can specify various space- and ground-based observation models with support for multiple coordinate and reference frames. SSAPy also supports orbit analysis and propagation methods such as multiple hypothesis tracking and has built-in uncertainty quantification. The majority of SSAPy’s methods are vectorized and parallelizable, allowing for effective use of high-performance computer (HPC) systems. Finally, SSAPy has plotting functionality, allowing users to visualize orbits and trajectories. Examples are shown in Figure 1 and Figure 2.

97 MATHEMATICS AND COMPUTING

Terra-Populus v0.1: A Python Library for LandScan High-Definition Population Analysis and Modeling

The terra-populus library is designed for use by the LandScan HD technical team, offering a streamlined set of tools for generating and updating LandScan HD datasets from foundational building-level data, referred to as 'molecules,' provided by the building-level attribution team. This document serves as the primary technical documentation for terra-populus. Version 0.1 of the library includes the core modeling components necessary for LandScan HD production. It enables the generation of the LandScan HD Baseline dataset as well as corresponding confidence measures for the occupancy rates used. Parameters have been included for incorporating damaged building indicators and changes in population, to faciliate the creation of rapid updates for LandScan HD. Future iterations of terra-populus will introduce tools for creating a confidence index, and quantifying and propagating uncertainty, facilitating the creation of probabilistic LandScan HD outputs. This report provides an overview of the tools available in the library and the corresponding code implementations. One of the key advancements implemented in terra-populus is a redefinition of the atomic modeling unit for LandScan HD. Traditionally, the LandScan HD vector analytical framework has generated population estimates at the building sub-component (molecule) level. However, terra-populus adopts a building-level modeling approach. This shift is an operational decision aimed at aligning LandScan HD outputs with confidence measures, which are computed and validated at the building level (confidence measures are not included in this version of terra-populus, aside from those associated with the occupancy rates). Additional advancements to the LandScan HD modeling, as implemented by terra-populus, include a minimum population value parameter and an auto assignment of building floor counts. The population minimum value was implemented to prevent buildings and subsequent LandScan HD pixels that contained small values that may not rasterize in production. An 'auto' value has been included as a method for dealing with buildings lacking floor count information, where it is the average floor count of all other buildings with a residential building use type tag. The logic behind this is to remain consistent with the current logic employed for dealing with building use type null instances, where a null use type is defaulted to residential since it is the most common building type. The auto logic is intended to apply the most common building floor count of the most common type of buildings. The tools provided in terra-populus represent a significant step forward in improving the efficiency, reproducibility, and transparency of the LandScan HD modeling process. As the library evolves, it will continue to serve as a foundational resource for high-resolution population modeling.

96 KNOWLEDGE MANAGEMENT AND PRESERVATION

MARIE: A Python-Based Framework for Comprehensive Fuel Recycling Modeling

One of the most pressing challenges to the continued deployment of nuclear energy systems is in the ultimate management and disposition of discharged fuel assemblies. While reprocessing and recovery of valuable materials from UNF assemblies has been considered as part of an overall strategy for minimization of the volume of reactor-based wastes to be managed, the deployment of commercial-scale reprocessing facilities presents an enormous economic challenge. The MARIE software package has been developed as a means of confronting this challenge. Representing components of a generic fuel reprocessing operation as individual physical processes, MARIE is designed as a modular framework intended to allow for analysis and cost-optimization for a hypothetical reprocessing facility while realistically accounting for the physical characteristics of the used fuel source term, such as decay heat, activity, and radiation dose (informing corresponding shielding requirements). Capabilities supported by MARIE include head-end operations such as fuel shearing, voloxidation, and dissolution; generic solvent extraction operations informed by available open-literature data; a suite of unit operations intended to represent electrochemical processing of used fuel assemblies (i.e., oxide reduction, electrorefining, and electrowinning); and finally, accounting for both costs and physical features of discharged waste streams, which can be used to inform follow-on analyses such as the feasibility of deep-borehole disposal of HLW. This paper presents an overview of the MARIE software capabilities, including how individual unit operations are implemented to enable a larger-scale optimization of a hypothetical reprocessing operation on aspects such as cost and recovery of valuable materials.

Skutnik, Steve [ORNL] (ORCID:000000016441135X)

A bespoke model of Arctic river basins based on hillslope delineation: Model Archive

This dataset is a model archive of the paper A bespoke model of Arctic river basins based on hillslope delineation (in prep), which introduces a watershed decomposition and parameterization method for large scale permafrost hydrology simulation. With this dataset, this study aims to address the research question: whether a computationally efficient hillslope-based modeling framework can reliably simulate discharge at Arctic river-basin scales. This dataset contains model input and output data for five modeling scenarios at a study site located in the Sagavanirktok River basin. The five modeling scenarios include three modeling cases under temperate conditions using full 3D, decomposed 3D, and decomposed 2D modeling strategies; and two modeling cases under actual Arctic conditions with permafrost using full 3D and decomposed 2D modeling strategies. Simulations were performed using the Advanced Terrestrial Simulator (ATS, v1.6 for three temperate scenarios and v1.5 for two Arctic scenarios), a physics-rich integrated surface–subsurface hydrologic model with cryo-hydrology features. For the three temperate models, simulations were conducted for the period of 10/01/1993 - 09/30/2002; and for the two Arctic models, simulations were conducted for the period of 01/01/1994 - 12/31/2002. To facilitate reproducibility of simulations, all datasets are organized hierarchically. The dataset contains: (1) Mesh files (.exo) for full 3D model, decomposed 3D models, and decomposed 2D models, located in huc/190604020802_gauge15906000/mesh/. Mesh files can be visualized through Paraview or read by Python. (2) Climate forcings (.h5) for full 3D model and decomposed 3D/2D models are located in huc/190604020802_gauge15906000/daymet_onePiece/, and huc/190604020802_gauge15906000/vp_pr_revised_daymet_1980_2006_with_wind/ separately. Accessible by Python. (3) Raw measured gage discharge (.csv) from USGS, located in huc/190604020802_gauge15906000/gaged_basin15906000_discharge_usgs/. Accessible by Python. (4) Delineated subdomain raster (.tif) and shape files (.shp), and the final parameterized results (.npy) for decomposed models, located in huc/190604020802_gauge15906000/data_preprocessed-meshing. Accessible by Python. (5) Temperate models are located in nonpermaf_huc190604020802_gauge15906000/, which includes three cases: decomposed 2D models (inside model_0*-hillslope_*), decomposed 3D models (inside model_1*-subcatchment_*), and full 3D model (inside model_2*-onepiece_*). Two step spin-up results (checkpoint_final.h5) are located in model_*1-*_spinup_steadystate and model_*2-*_spinup_cycle, separately, which are used to initialize real transient models. The input files (.xml) and output results (.dat) of the real transient models are located in model_*3-*_transient/. Especially, for two example hillslope models (ID=-11 and 11), additional h5py files are included in model_03-hillslope_transient/hillslope-11/, model_03-hillslope_transient/hillslope11, model_13-subcatchment_transient/subcatchment-11/, model_13-subcatchment_transient/subcatchment/11, respectively, which are used to plot the saturation figure (Figure 5) in the manuscript. Accessible by Python. (6) Arctic models are located in huc190604020802_gauge15906000/, which includes two cases: decomposed 2D models (inside model_04-hillslope_transient), and full 3D model (inside model_05-onepiece_transient_mannp1_ra). Three step spin-up results (checkpoint_final.h5) are located in model_01-column_freezeup/, model_02-column_spinup/, model_03-hillslope_spinup/, respectively, which are used to initialize real 2D transient hillslope models. The input files (.xml) and output results (.dat) of transient 2D hillslope models are located in model_04-hillslope_transient/. The input files (.xml) and output results (.dat) of the full 3D transient model is located in model_05-onepiece_transient_mannp1_ra/. The full 3D transient model is initialized by model_02-column_spinup/. Accessible by Python. (7) The MOSART routed discharge results (.csv) under Arctic conditions is located in huc190604020802_gauge15906000/MOSART/. Accessible by Python. (8) All Python codes (.py) used to parameterize full 3D model to decomposed 2D models are located in script/. These codes fit with watershed workflow (a watershed delineation tool) v1.4 under the branch gaob/v1.4 from https://github.com/gaobhub/watershed-workflow.git.

EARTH SCIENCE > CRYOSPHERE

Hydrologic Model Data for the East Fork Poplar Creek Watershed Simulated with the Advanced Terrestrial Simulator (ATS): Streamflow and Network Expansion–Contraction Dynamics

This dataset supports hydrologic modeling and stream network expansion–contraction analysis for the East Fork Poplar Creek (EFPC) Watershed in Tennessee. It includes a Jupyter notebook for model setup, model configuration files, simulation outputs, and derived products used to evaluate model performance and investigate stream dynamics under varying hydrologic conditions. The dataset was generated using the Watershed Workflow Python package and the Advanced Terrestrial Simulator (ATS), enabling integrated surface–subsurface hydrologic simulations using a stream-aligned mesh. Outputs include high-resolution time series of streamflow, active network length, water table depth, and related hydrologic variables. Also included are spatially explicit stream persistency indices and classifications of reaches as perennial or non-perennial. These data facilitate reproducibility and support further research on stream intermittency and variability in network extent.The model data archive is organized in following directories:1) model_setup_inputsContains the Watershed Workflow Jupyter notebooks (accessed through any open source code editor), selected input datasets, and resulting ATS input files, including XML files (access through any open source code editor), computational mesh (.exo files can be viewed using Paraview), and meteorological forcing files (.h5 files can be accessed through h5py python package and HDFView open source software). 2) model_outputsIncludes ATS simulation outputs relevant to this study. Time series of spatially integrated or averaged variables (e.g., streamflow, water table depth) are provided as CSV files. Select spatial fields (e.g., ponded depth and water table depth) are saved as pickled Python objects to reduce file size, and can be accessed through pickle package in Python. Key geometry objects from Watershed Workflow—such as the surface mesh and river tree—are also included to support analysis of streamflow persistency and expansion–contraction dynamics. These files can also be accessed through Watershed Workflow Python package.3) model_evaluationProvides observed streamflow time series and field survey-based flow regime classifications used to evaluate model performance. Jupyter notebooks for processing ATS outputs and comparing model predictions with observations to build confidence in the model prior to scientific analysis are also included.4) Q_L_relationshipsContains workflows for generating time series of discharge, active network length, and related hydrologic variables used in the stream network expansion–contraction analysis. Includes routines for delineating baseflow-dominated periods. For each catchment, notebooks and processed data (as pickled DataFrames accessed through Pandas Python package) are provided. 5) figure_scriptsProvides the Jupyter notebooks used to generate the figures presented in the paper.

54 ENVIRONMENTAL SCIENCES

PFLOTRAN modeling data and scripts associated with “Refining the Hydrogeologic Framework of a Large River Corridor Model Using Waterborne Transient Electromagnetics”

NOTE: The manuscript associated with this data package is currently in review. The data may be revised based on reviewer feedback. Upon manuscript acceptance, this data package will be updated with the final dataset and additional metadata. This data package is associated with the publication “Refining the Hydrogeologic Framework of a Large River Corridor Model Using Waterborne Transient Electromagnetics” submitted to Water Resources Research (Terry et al. 2025). The data package contains the groundwater modeling dataset from PFLOTRAN software. It includes the python script for mesh generation, boundary condition setting, PFLOTRAN input deck formation and postprocessing. It couples groundwater flow and species transport for Hanford Reach river corridor and pipelines the model generation and processing. This model can be used to easily generate the model and analysis for Hanford site. It can also be adjusted to other hydrologic area with ease. For details on how to navigate data packages generated by this project, see https://data.ess-dive.lbl.gov/portals/PNNLRiverCorridorSFA/About. The data package consists of 6 folders: (1) “data” contains all necessary data as input and intermediate data for processing; (2) “mesh” contains all mesh related files to generate mesh in Hanford Reach river corridor; (3) “model_run” contains the generated script for PFLOTRAN modeling; (4) “notebooks” contains all the Python script to generate the model; (5) “output” contains all the output from the computation; (6) “postprocessing” contains the Python script to generate scientific figure for manuscript. All files are .csv (comma-separated values), .h5 (HDF5 format), .in (input files), .ipynb (Jupyter notebooks), .p (Python pickle), .png (images), .PNG (images), .py (Python scripts), .pyc (Python bytecode), .r (R scripts), .sh (shell scripts), .txt (text files), .vtu (3D mesh/visualization format), .xz (compressed archive), or .zip (compressed archive).

54 ENVIRONMENTAL SCIENCES

Urban morphology and urban water demand evolution in the Los Angeles region

Detailed description of the dataset sources used in this study, the experimental workflow, and plotting for the paper figures provided at the associated GitHub Meta Repo: https://github.com/IMMM-SFA/Ferencz_et_al_2024_ERL The future water demand projections from this study are hypothetical future water demands that reflect the population and urban land cover changes represented by the scenarios considered. The intent and emphasis of this work is investigating the interactions between population change, evolution of urban morphology, and water demand. These projections are not meant to be likely future demands for specific water providers or the LA region and should not be interpreted as such. The folders contain input and output data for each step of the "Recreate my Experiment" workflow described in the associated GitHub meta-repository as well as data used for plotting Figures for the paper that this dataset supports. Description of each folder's contents and use: Step_1a: Inputs to the associated python script provided on the GitHub repo. Step_1b: Inputs (downscaled population rasters) used by the associated python script provided on the GitHub repo. Original 1-km squared rasters that were downscaled also provided. Step_1c: Urban growth projection rasters corresponding to SSP3 and SSP5 population scenarios are provided in separate subfolders as well as the water provider boundaries used for analysis. Outputs of data processing also provided. Associated python script provided on GitHub. Step_1d: Description of Inputs used by the QGIS Model Builder GUI that automates geospatial processing and clipping the of the high-resolution 60 cm land cover data for each urban land class footprint within a defined polygon boundary. The Model Builder is provided on the GitHub repo and can be used by QGIS. The outputs of this step are in "Clipped Provider Hi Res Landcover". If the user wants to use The Model Builder for different regions of LA or to test our outputs, they will need to download the hi resolution landcover raster listed in the Readme and in Ref [2] of the GitHub Page. Step_1e: All necessary inputs to generate average monthly demand over the 2017-2021 period and the minimum and maximum demands over the 2014-2021 for each water provider. Associated python scripts are on GitHub. Step 2: Output data about land cover metrics (areas and fractions) for each urban land class for each water provider. Associated python script on GitHub. Uses outputs from Step 1d "Clipped Provider Hi Res Landcover" Step 3: Both the Inputs for and Outputs from the urban projection raster analysis Python script on GitHub. The inputs are urban land class rasters for specific SSP and zoning scenarios (low, medium, high) from Step 1c. The outputs are rasters of urban pixels that were converted to a higher land class and the number of land class units that changed (Values of 1, 2, or 3). For example, a value of 2 could be LC 21 -> 23 or LC 22 -> 24. These maps are label "intensification." The other outputs are "urban growth" rasters showing the conversion of non urban to urban land, which are indicated by pixel values of 1. These are used for the urban growth change maps in Figure 3. Step 4: Output projections of indoor and outdoor annual and monthly demands for each water provider for the average, minimum, and maximum monthly demand scenarios for each of the four urban growth scenarios (SSP3 med, SSP5 low, SSP5 med, and SSP5 high). The outputs also include metrics on each water provider used for the demand sensitivity analysis presented in Figure 8. Outputs from Step 4 are used for Figures 4 - 8 of the paper. Figures: This folder has data used for plotting Figures 1 through 5, and 8. Data for Figures 6 and 7 are sourced directly from folders associated with the Processing and Analysis Steps 1 - 4. The GitHub meta repository provides descriptions of how each figure was made and the associated plotting scripts used.

Los Angeles

Deep Learning-based Non-Stationary Bias Correction (NSBC)

This work develops the NSBC (non-stationary bias correction) methodology to correct temperature projection bias from E3SM. The NSBC deep learning framework consists of a three-part architecture: an auto-encoder for compressing the spatial information, an LSTM for predicting annual temperature mean, and a U-Net for capturing the residual bias in temperature. The non-stationary bias correction (NSBC) framework can correct the non-stationarity of the biases of the climate models, which significantly improves the accuracy of future temperature prediction and improves the overestimation of extreme high temperatures that many existing bias correction methods suffer from. Getting started 1. Obtain the historical climate simulation and observation data. The E3SM simulation data are available through https://aims2.llnl.gov/search/cmip6/. The pseudo observations, the Geophysical Fluid Dynamics Laboratory (GFDL)-ESM4 model (Krasting et al., 2018) are available through https://aims2.llnl.gov/search/cmip6/. The spatial resolution of E3SM and pseudo observation datasets are both regridded to a common 1° resolution grid using conservative interpolation. The regridded E3SM and pseudo observation with 1° resolution can be found throught ./data/. 2. Train the Auto-encoder model. Python 0-autoencoder.py 3. Train the LSTM Python 1-LSTM.py 4. Generate the annual mean temperature based on trained LSTM Python 2-generate_annual_mean_LSTM.py 5. Train the U-Net. Python 3-unet.py 6. Evaluation and compared with the baseline Python 4_evaluation.py Is there a deadline approaching that requires the release of yo

Lucas, Donald

stor4build

The EnergyPlus simulation engine supports modeling and simulation of thermal energy storage (TES) systems in several ways, including using the Python-EMS feature, which extends the operation of the engine with custom code written in Python. Creation of models using this feature can be tedious and error prone, with the connection of the model components to the Python code a particularly troublesome area. The stor4build Python package simplifies this process by modifying an input model to add a selected TES technology (implemented with the Python-EMS feature) and runs the simulation. The package leverages the OpenStudio middleware software development kit to automate this process as much as possible, eliminating potential errors and simplifying usage of EnergyPlus. The package provides objects, functions, and OpenStudio measures that implement the necessary operations to automate the creation of EnergyPlus models that integrate TES technologies with building systems. In addition, two user interfaces are provided: a command line interface and a web application programming interface. The automated process implemented by the package greatly simplifies the modeling and simulation process, allowing for parametric studies to be executed much more efficiently and effectively. The OpenStudio-based workflow is also very flexible and will allow for future additions of new technologies.

DeGraw, JasonWilliam [Oak Ridge National Laborator

sourcePy

Pollutant source identification techniques (of which there are many variations) are either locked behind researchers writing their own code for each use case or GUI platforms that are easy to use but inflexible and opaque. The Python package sourcePy brings together many of the pollutant source identification algorithms, giving the user full control out of the box. It aims to create a platform for source identification experiments where the full analysis from beginning to end can be done in Python, with a level of specificity in design that isn't available in the GUI options. sourcePy provides users with a few key features: -A Python interface with HYSPLIT, which can be used to generate trajectories and concentration plumes -Several Python classes which standardize the preparation and processing of data related to source identification experiments -Example scripts and notebooks that allow even new python users to get started with their own experiments quickly -Visualization methods

Arseneau, Isaac [Oak Ridge National Laboratory (OR