Recent Releases of kuibit
kuibit - 1.5.2 / 1.5.1
Version 1.5.2 (2 July 2025)
(Version 1.5.2 doesn't really exist. Version 1.5.1 had a workflow error)
Version 1.5.1 (2 July 2025)
General
- Python 3.13 is now supported.
Bug fixes
- Added support to ready HDF5 files created with very old versions of Carpet (< 2012).
- Fixed calculation of masses in
hor_utils. Previously the mass was assumed proportional to the area (and not its squared root) (@xuyumeng) - Fixed outdated call to
scipy.integrated.cumtrapz(@meyersbs) - Fixed applications of window functions with new versions of SciPy
- Fixed NumPy deprecation warnings
Scientific Software - Peer-reviewed
- AGS Script
Published by github-actions[bot] 8 months ago
kuibit - 1.5.0
Version 1.5.0 (19 June 2024)
General
- Python 3.12 is now supported, Python 3.8.1 is required for development.
total_filesizenow errors out when directories are passed.
Features
- Added experimental support for reading OpenPMD files (with most of the heavy-lifting done by @krishivbhatia). Please, report any issue you might find.
Scientific Software - Peer-reviewed
- AGS Script
Published by Sbozzolo over 1 year ago
kuibit - 1.4.0
Version 1.4.0 (2 May 2023)
General
- Minimum version of Python required is now 3.7.
kuibitnow explicitly follows NEP29. - Started gradual typing
- Now
SimDircan be imported directly fromkuibit(from kuibit import SimDir) - Update logo to high resolution (and vector graphics)
Features
- Added linear momentum lost by gravitational waves along the x and y directions (starting from a contribution by @konrad-topolski)
- Added
Treedata structure - Added
effective_amplitude_spectral_densitywithingw_utils(starting from a contribution by @irrationalnumbers, #27) - Added fourth order accuracy in finite differences of grid functions
- Added
copyto gravitational and electromagnetic waves - Added
cropandcroppedto multipole data setup_matplotlibnow takes an optional parameterrc_param_fileto configure matplotlib using a file- Added computation of linear momentum lost by electromagnetic waves
- Added
rotation180_symmetry_undoto undo rotational symmetries in grid data - Added
cactus_twopuncturesto read metadata from TwoPunctures - Added
local_maximaandlocal_minimato series - Added
mean,average,median,stdreductions to series and grid data - Added
ah_available,qlm_availabletoOneHorizon - Added
tensormodule - Added support to
surface*.vtkfromQuasiLocalMeasures
Support to VTK variables from QuasiLocalMeasures
QuasiLocalMeasures has an option to output its variables on the horizon. Now, kuibit can read and parse them, so it is possible to plot horizon meshes and variables onto the mesh.
New tensor module
kuibit.tensor is a new module to provide high-level interfaces to work with tensorial objects. A Tensor can be built with collections of TimeSeries, FrequencySeries, UniformGridData, HierarchicalGridData, or any other class derived from BaseNumerical. Tensors support all the mathematical operations and inherit the methods from their contained object. At the moment, there are two new subclasses of Tensor that implement additional features for vector calculus. For example, if bh_cen is a Vector with the time evolution of the centroid of an horizon. bh_cen.differentiated().norm() will be a TimeSeries with the magnitude of the coordinate velocity as a function of time (as a TimeSeries).
Currently, the number of specialized methods in Vector and Matrix is not large. Nonetheless, the infrastructure is in place and adding new will be straightforward.
New cactus_twopunctures module
TwoPunctures creates a metadata file that stores important physical information about the initial data. The new module cactus_twopunctures can read this information and present it as a dictionary. If sim is a SimFactory, sim.twopunctures will be a dictionary-like object that has as keys the various quantities saved by TwoPunctures and as values, their values as read from the TwoPunctures.bbh` file.
New tree module
kuibit.tree is a new module that can represent tree structures. At the moment, it is main use is to work with timer trees.
New hor_utils module
kuibit.hor_utils is a handy new module that implements common functions needed when working with binary black holes. At the moment, the functions implemented are:
compute_separation_vectorcompute_separationcompute_center_of_masscompute_angular_velocity_vector
Bug fixes
- Fix passing an empty
ah_varstoOneHorizon. - Fix floating-point comparison in
grid_data. - Fix optional positional arguments to
series._local_extrema. - Fix algorithm to compute hash for
UniformGrid. - Make classes that should not hashed unhashable.
GravitationalWavesnow find multipole variables that containpsi4(as opposed to being identically toPsi4)
Detector sensitivity curves
- Add more updated sensitivity curve for Einstein Telescope (ET-D) (thanks, @bgiacoma, #33).
New/updated examples
Scripts:
describe_simdir.pyinteractive_timertree.pyprint_available_iteration.pyoptionally prints the corresponding timeplot_charge_phi1.pyplot_binary_ah_angular_velocity.pyplot_binary_ah_period.py
Scientific Software - Peer-reviewed
- AGS Script
Published by github-actions[bot] almost 3 years ago
kuibit - 1.3.4
Version 1.3.4 (22 April 2022)
General
- Improvements to documentation and docstrings
Bug fixes
- Added error in
_plot_horizon_on_planewhen the horizon cannot be plotted - Updated NumPy types (np.int -> int, np.float -> float)
- Windowing uneven signals is no longer allowed
- Correctly remove ghost zones for 1-2D HDF5 files
- Fix deprecation warning for Matplotlib 3.4
- Fix
is_maskedafter removing a mask (thanks @ekwessel, #28) - Fix some information not being propagated by
grid_data_utils.merge_uniform_grids.
New examples
Scripts:
plot_ah_trajectories.py
Scientific Software - Peer-reviewed
- AGS Script
Published by github-actions[bot] almost 4 years ago
kuibit - 1.3.2
Version 1.3.2 (16 November 2021)
Bug fixes
- Examples with
plot_components_boundariesnow respect axes limits - Improved support to installing
mayavi Python 3.10is now supported (with exception ofnumba)- Fixed parity in
reflection_symmetry_undo
Scientific Software - Peer-reviewed
- AGS Script
Published by github-actions[bot] over 4 years ago
kuibit - 1.3.0
Version 1.3.0 (28 October 2021)
SimDir can now be cached in pickle files
kuibit tries to do as much lazy-loading as possible. For examples, files are opened only when needed. When analyzing simulations it is useful to save the work done by kuibit to avoid re-doing the same operations over and over. It is now possible to do this using pickle files. SimDir can now be used as a context manager and the progresses can be loaded and saved from files. For example:
python
with SimDir("path_of_simulation", pickle_file="simdir.pickle") as sim:
# do operations
In this case, if pickle_file exists, it will be loaded (ignoring all the other arguments passed to SimDir), and it will be kept updated with the additional work done by kuibit. If pickle_file does not exist, the SimDir will be created as usual as a pickle_file will be generated.
It is important to stress that, when using pickles, no consistency check with the current state of the simulation is performed. If the simulation changes (e.g., new checkpoints are added), this will result in errors. In that case, a new pickle file must be produced.
Masked data
Numerical objects now support mask, which can be used to ignore part of the data that satisfy certain conditions (for example, to exclude the atmosphere from GRMHD computations).
Note that it is not possible to perform interpolation with masked data, so several methods will not work.
Note also that we mask only the data, not the independent coordinate (e.g., the time in TimeSeries or the spatial coordinates in the UniformGridData). In case you need masked coordinates too, you can use the mask method to obtain an array of booleans that identifies the valid data.
Series,UniformGridData,HierarhicalGridDatahave a new methodis_masked.Series,UniformGridData,HierarhicalGridDatahave a new methodmaskthat identifies where data is invalid.Series,UniformGridData,HierarhicalGridDatahave news methods to create masked data (e.g.,mask_greater). See complete list in documentation.Serieshave new methodsmask_removeandmask_removedto create objects without masked data.Serieshave new methodsmask_applyandmask_applyedto create objects with a given mask (as the one obtained with themaskmethod).
General
SimDircan be saved to disk with the methodsaveand read with the functionload_SimDir. This is useful to work with a simulation that has finished.- Examples can now use pickles.
- New CI workflow: linting.
- New
First Stepsdocumentation page. - When a release is published, its documentation is saved to
sbozzolo.github.io/kuibit/VERSION
Features
time_at_maximumandtime_at_minimuminTimeSeriescan now take the optional argumentabsolute.- Added
x_at_minimum_yandx_at_maximum_ytoBaseNumerical. - Added
coordinates_at_maximumandcoordinates_at_minimumfor grid data. - Added
HierarchicalGridData.is_complex(). - Added
tikz_clean_figuretovisualize_matplotlib.save, toargparse_helper.add_figure, and to examples. This can be used to reduce the size of outputtikzfiles. - Added
clear_cacheinOneGridFunction. - Added
plot_contour. - Added alias
time_foundtoformation_timein horizons. - Added
plot_components_boundaries. - Added
ghost_zones_removeinHierarchicalGridData - Added
add_grid_structure_to_parser. - Added
reflection_symmetry_undone.
Breaking changes
- The
ignoreparameter inSimDirhas been renamed toignored_dirs. - The
trim_endsparameter incactus_wavesis now set toFalseby default.
Bug fixes
plot_colorbardoes not steal axis focus anymore.- The legend in
plot_psi4_lmwas corrected. visualize_matplotlib.savenow correctly supports thefigureargument.plot_strain_lm.pyno longer crashes whenwindow_argsis not provided.HierarchicalGridDatanow owns the components.- Clear
OneGridFunctioncache ingrid_varto avoid death by OOM. - Uniform constructor of
GridSerieswith constructors of otherSeries. - Horizon properties now lead to valid python variable names.
New examples
Examples with --detector-num now also accept --num-detector as alias.
Scripts:
picklify.pyplot_1d_slice.pyplot_grid_expr.pyplot_phi_time_averaged.pyplot_gw_angular_momentum.pyprint_grid_point_minmax.py
Scientific Software - Peer-reviewed
- AGS Script
Published by github-actions[bot] over 4 years ago
kuibit - 1.2.0
Version 1.2.0 (1 June 2021)
New module: visualize_matplotlib
The visualize_matplotlib module aims to simplify common visualization tasks with matplotlib. At the moment, it mainly supports visualizing grid data and apparent horizons outlines. The public functions in visualize_matplotlib try to be as general as possible: if you pass some grid objects, they will try to figure out how to plot it. Nonetheless, you should read the documentation and the docstrings of the various functions.
motionpicture
Making movies is a critical step in analyzing a simulation. Now, kuibit comes with motionpicture, a Python tool to assist you animate your data. motionpicture provides all the infrastructure needed to render multiple frames and glue them together, so, all you need to worry is how to render one single frame. Importantly, motionpicture supports parallel rendering, which can dramatically speed up the time needed to produce a video. Check out the grid_var example to see how easy it is to make a movie.
New class: GridSeries
GridSeries is a new class to describe 1D grid data. This class utilizes the same infrastructure used by TimeSeries and FrequencySeries to represent a single-valued function. UniformGridData can be transformed into GridSeries with the method to_GridSeries. The main reason you would want to do this is because GridSeries are leaner and more direct to use.
General
- Improvements to documentation, docstrings, and tutorials
- Examples are now automatically packaged and uploaded upon release
- New YouTube series,
Using kuibit
New examples
Scripts:
plot_1d_vars.pyplot_ah_coordinate_velocity.pyplot_ah_found.pyplot_ah_radius.pyplot_ah_separation.pyplot_constraints.pyplot_em_energy.pyplot_grid_var.pyplot_gw_energy.pyplot_gw_linear_momentum.pyplot_physical_time_per_hour.pyplot_phi_lm.pyplot_psi4_lm.pyplot_strain_lm.pyplot_timeseries.pyplot_total_luminosity.pyprint_qlm_properties_at_time.py
Movies:
grid_var
Bug fixes
- Fixed header recognition for
carpet-grid.asc(#22)
Features
- New methods
get_apparent_horizonandget_qlm_horizoninHorizonsDir.
Scientific Software - Peer-reviewed
- AGS Script
Published by github-actions[bot] over 4 years ago
kuibit - 1.2.0b0
Version 1.2.0 (Under development)
New module: visualize_matplotlib
The visualize_matplotlib module aims to simplify common visualization tasks with matplotlib. At the moment, it mainly supports visualizing grid data and apparent horizons outlines. The public functions in visualize_matplotlib try to be as general as possible: if you pass some grid objects, they will try to figure out how to plot it. Nonetheless, you should read the documentation and the docstrings of the various functions.
motionpicture
Making movies is a critical step in analyzing a simulation. Now, kuibit comes with motionpicture, a Python tool to assist you animate your data. motionpicture provides all the infrastructure needed to render multiple frames and glue them together, so, all you need to worry is how to render one single frame. Importantly, motionpicture supports parallel rendering, which can dramatically speed up the time needed to produce a video. Check out the grid_var example to see how easy it is to make a movie.
New class: GridSeries
GridSeries is a new class to describe 1D grid data. This class utilizes the same infrastructure used by TimeSeries and FrequencySeries to represent a single-valued function. UniformGridData can be transformed into GridSeries with the method to_GridSeries. The main reason you would want to do this is because GridSeries are leaner and more direct to use.
General
- Improvements to documentation, docstrings, and tutorials
- Examples are now automatically packaged and uploaded upon release
New examples
Scripts:
plot_1d_vars.pyplot_ah_found.pyplot_ah_radius.pyplot_ah_separation.pyplot_constraints.pyplot_em_energy.pyplot_grid_var.pyplot_gw_energy.pyplot_gw_linear_momentum.pyplot_physical_time_per_hour.pyplot_phi_lm.pyplot_psi4_lm.pyplot_strain_lm.pyplot_timeseries.pyplot_total_luminosity.pyprint_qlm_properties_at_time.py
Movies:
grid_var
Features
- New methods
get_apparent_horizonandget_qlm_horizoninHorizonsDir.
Scientific Software - Peer-reviewed
- AGS Script
Published by github-actions[bot] almost 5 years ago
kuibit -
Version 1.1.0 (18 April 2021)
New module: argparse_helper
The argparse_helper module collects functions to set up arguments for command-line scripts. It comes with options for working with figure, grid data, and horizons. Options can be stored in text files and read passing the path to the -c flag.
Faster HierarchicalGridData
The function that finds the component corresponding to a given point in HierarchicalGridData was significantly sped up by adopting the algorithm used in PostCactus (developed by Wolfgang Kastaun). This new algorithm is significantly faster, but it will not work in case the refinement factors across different levels are not constant integers. In that case (e.g., the refinement boundaries are at 1, 2, and 6), the older algorithm will be used. For large towers of refinement levels and hundreds of MPI processes, the new algorithm is orders of magnitude faster.
Examples
Now kuibit comes with runnable examples. These are production-grade codes that you can immediately use for your simulations. They are a great way to learn about how to use kuibit. The examples included are:
print_ah_formation_time.pyprint_available_iterations.pyprint_available_timeseries.pysave_resampled_grid_data.py
General
- Releases are now automatically pushed to PyPI.
Features
- Added method to compute the linear momentum lost by gravitational waves
- Now the method
saveinUniformGridDatasupports.npzfiles. This is the recommend and fastest way to save aUniformGridDatato disk. - The function
load_UniformGridDatacan now read.npzfiles.
Bug fixes
- Fixed bug that, under certain circumstances, resulted in
cactus_grid_functionnot correctly indexing all the 3D data files - Fixed a test that was triggering the wrong error.
- Fixed a bug that made
ra_dec_to_theta_phidepend on the local time
Breaking changes
finest_level_component_at_pointis nowfinest_component_at_pointand returns directly the component asUniformGridDataas opposed to the refinement level and component number.
Scientific Software - Peer-reviewed
- AGS Script
Published by Sbozzolo almost 5 years ago