-
Notifications
You must be signed in to change notification settings - Fork 1
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fix #19
base: libyt
Are you sure you want to change the base?
Fix #19
Conversation
…n situ. We need this because libyt does not make a copy of the names.
I don't know why there is two grid showing active particle count = 1. There should only be one particle in this run, not sure if it overlapped.
It pre-allocates buffers to store a copy of attribute data. They will free them when libyt ends.
…are not correct) The attributes are put in a new allocated buffer. It will be freed when in situ analysis are done.
This is caused by GetAttribute _shifts_ the pointer passed in when returning.
@matthewturk , I totally forget about this PR. This PR supports active particles and derived fields (though limited to |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
minor feedback otherwise LGTM
@matthewturk I have fixed the issues. |
I think I should also update the version of libyt in the doc. |
Done! |
Fix bugs, Load Active Particles and Derived Fields
Doc
sm,pt2pt
.Bugs
Gamma
togamma
, since enzo's yt frontend readsds.gamma
.velocity_unit
,magnetic_unit
,periodicity
.EYT_PINT
toYT_LONGLONG
when-DCONFIG_PINT_8
. (Note that in this setting, MPI is mapped toMPI_LONG_LONG_INT
.)Derived Fields
Temperature
,Cooling_Time
) and assign them as enzo inline fields. This avoids looking up grid ID when usinglibyt
's generating data from C-function.Active Particles
libyt
.libyt.h
inParticleAttributeHandler.h
. And because hdf5 is a mandatory dependency, using hdf5 data type to map to yt data type won't have any conflict.GetParticleAttributeNames
,GetParticleAttributes
, andGetParticleAttributesHDF5DataType
are created inActiveParticleHelpers
namespace. They are used in libyt only. Since the active particle is created via aregister_ptype
function layer, adding them here will not alter the original behavior of the active particle.GetParticleAttributes
allocates a new data buffer and callsGetAttribute
to fill in the buffer. These buffers will be freed after libyt is done. Currently, we only get the attributes that have 1 dimension. (Notice thatGetAttribute
shifts the buffer pointer when returning.)