Skip to content

Feature: Add a scalar and vector data field to VTK write test [2/3] #1488

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

Open
wants to merge 30 commits into
base: main
Choose a base branch
from

Conversation

holke
Copy link
Collaborator

@holke holke commented Mar 20, 2025

Closes #1629

Describe your changes here:

The first step towards #1487.
The vtk_writer example did not write any user data.
Extended the example with 2 data fields, one scalar, one vector and dummy data.
The data fields do already contain values for the ghost elements.

All these boxes must be checked by the AUTHOR before requesting review:

  • The PR is small enough to be reviewed easily. If not, consider splitting up the changes in multiple PRs.
  • The title starts with one of the following prefixes: Documentation:, Bugfix:, Feature:, Improvement: or Other:.
  • If the PR is related to an issue, make sure to link it.
  • The author made sure that, as a reviewer, he/she would check all boxes below.

All these boxes must be checked by the REVIEWERS before merging the pull request:

As a reviewer please read through all the code lines and make sure that the code is fully understood, bug free, well-documented and well-structured.

General

  • The reviewer executed the new code features at least once and checked the results manually.
  • The code follows the t8code coding guidelines.
  • New source/header files are properly added to the CMake files.
  • The code is well documented. In particular, all function declarations, structs/classes and their members have a proper doxygen documentation.
  • All new algorithms and data structures are sufficiently optimal in terms of memory and runtime (If this should be merged, but there is still potential for optimization, create a new issue).

Tests

  • The code is covered in an existing or new test case using Google Test.

If the Pull request introduces code that is not covered by the github action (for example coupling with a new library):

  • Should this use case be added to the github action?
  • If not, does the specific use case compile and all tests pass (check manually).

Scripts and Wiki

  • If a new directory with source files is added, it must be covered by the script/find_all_source_files.scp to check the indentation of these files.
  • If this PR introduces a new feature, it must be covered in an example or tutorial and a Wiki article.

Tag Label

  • The author added the patch/minor/major label in accordance to semantic versioning.

License

  • The author added a BSD statement to doc/ (or already has one).

@holke
Copy link
Collaborator Author

holke commented Mar 20, 2025

Note: even though writing of ghosts was set true (and not changed by this commit), the ghost elements do not seem to be written, which is odd.

@holke
Copy link
Collaborator Author

holke commented Mar 20, 2025

Note: even though writing of ghosts was set true (and not changed by this commit), the ghost elements do not seem to be written, which is odd.

Could be resolved, the forest in the example was build without a ghost layer.

@holke holke changed the title Feature: Add a scalar and vector data field to VTK write test Feature: Add a scalar and vector data field to VTK write test [2/3] Mar 21, 2025
@holke
Copy link
Collaborator Author

holke commented Mar 21, 2025

The tests fail in VTK API mode due to a ghost tree being requested by grid_element_shape and the function expecting only local trees.
@Davknapp is working on a solution.

@Davknapp Davknapp assigned Davknapp and holke and unassigned Davknapp Mar 21, 2025
@holke
Copy link
Collaborator Author

holke commented May 9, 2025

This currently fails due ghost trees not being considered in

grid_element_shape<t8_forest_t> (const t8_forest_t grid, const t8_locidx_t itree, const t8_element_t *element)
{
  const t8_eclass_t eclass = t8_forest_get_eclass (grid, itree);

Fix is easy, extend the function to accept ghost tree ids and call "get_ghost_tree_class" if so.
Must still decide whether "ist_ghost" should be added as parameter or will be computed by the function.

Edit: These were already adressed by @Davknapp and should be merged now.

@holke holke marked this pull request as draft May 9, 2025 20:13
@holke holke force-pushed the feature-extend_vtk_test_with_data branch from 9b7c069 to 4006086 Compare May 12, 2025 11:24
@holke holke force-pushed the feature-extend_vtk_test_with_data branch from 71db8ef to 59efd26 Compare May 12, 2025 12:04
@holke holke removed their assignment May 12, 2025
@holke holke marked this pull request as ready for review May 12, 2025 12:06
@holke holke requested a review from Davknapp May 13, 2025 13:37
@holke holke assigned Davknapp and unassigned holke May 13, 2025
@Davknapp Davknapp added this pull request to the merge queue May 26, 2025
@github-merge-queue github-merge-queue bot removed this pull request from the merge queue due to failed status checks May 26, 2025
@Davknapp Davknapp added this pull request to the merge queue Jun 12, 2025
github-merge-queue bot pushed a commit that referenced this pull request Jun 12, 2025
Feature: Add a scalar and vector data field to VTK write test [2/3]
@github-merge-queue github-merge-queue bot removed this pull request from the merge queue due to failed status checks Jun 12, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Feature: Add a scalar and vector data field to VTK write test [2/3]
2 participants