Skip to content
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

Support Derived Function and Particle Get Attribute Function Prepare Multiple Data Chunks At A Time #54

Open
3 tasks
cindytsai opened this issue Apr 14, 2022 · 0 comments
Assignees
Labels
enhancement New feature or request new-feature New feature. pri-future Priority: future project

Comments

@cindytsai
Copy link
Collaborator

cindytsai commented Apr 14, 2022

Support Derived Function and Get Attribute Function Prepare Multiple Data Chunks At A Time

Problem

  • Currently, derived_func and derived_func_with_name prepare one data grid at a time.
  • This may cause poor performance for code heavily use hybrid OpenMP/MPI (ex: gamer) to generate derived field.
  • This limits a derived function style. One must write derived function in a way libyt likes.
  • Though this problem isn't actually affecting libyt's overall performance for now.

Solution

libyt

Data Structure

  • Update New API and Other Miscellaneous #56
  • Update data members derived_func_chunk and derived_func_with_name_chunk in yt_field struct.
    • void (*derived_func_chunk) ( int list_length, long *list_gid, yt_array *data )
    • void (*derived_func_with_name_chunk) ( int list_length, long *list_gid, char *field, yt_array *data )
  • Update data member get_attr in yt_particle struct.
    • void (*get_attr) ( int list_length, long *list_gid, char *attr_name, yt_array *data_array)

Derived Function/Get Attribute Function C++ Extended Python Method

  • Python dictionary structure for wrapping them and storing them inside NumPy Array.

RMA

  • Since one will only need remote memory access when MPI size > 1. Do we really need to prepare many grid at a time if one already have parallelized in MPI?
  • Update yt_rma_field.cpp when preparing grid data for remote ranks.
  • Update init_libyt_module.cpp function libyt_field_get_field_remote so that it asks many grids at a time.

yt

  • Update io.py, find places to store grids.
  • Redesign _get_field_from_libyt, _read_chunk_data, and _read_fluid_selection.
@cindytsai cindytsai added enhancement New feature or request pri-future Priority: future project new-feature New feature. labels Apr 14, 2022
@cindytsai cindytsai changed the title Support Derived Function Prepare Multiple Data Chunks At A Time Support Derived Function and Particle Get Attribute Function Prepare Multiple Data Chunks At A Time Apr 24, 2022
@cindytsai cindytsai self-assigned this Apr 26, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request new-feature New feature. pri-future Priority: future project
Projects
None yet
Development

No branches or pull requests

1 participant