pynucastro.yt_utils module

pynucastro.yt_utils module#

A collection of methods for accessing data from a simulation using yt and putting it in a form that pynucastro can use.

pynucastro.yt_utils.get_point(ds, pos)[source]#

Get a specific point from a yt dataset object.

Field values can be extracted by subscripting: point['Temp'].

Works around various annoyances with the argument handling in ds.point(), so things like get_point(ds, ds.all_data().argmax('enuc')) work as expected for all coordinate systems.

Parameters:
Return type:

yt.data_objects.selection_objects.point.YTPoint

pynucastro.yt_utils.to_conditions(point)[source]#

Extract the thermodynamic conditions needed to evaluate a network from a YTPoint object.

Returns:

tuple of (rho, T, composition)