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

Add vector support for preCICE interface #28

Merged
merged 2 commits into from
Oct 11, 2021

Conversation

kursatyurt
Copy link
Collaborator

This PR adds vector data support for preCICE interface which is missing

Copy link
Member

@davidscn davidscn left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The changes make sense, but seem a bit small in general. Do you really adjust the size of the data container (needs to be dim x ids.size() in the vector valued case.) and do where does the isVector comes from?

@kursatyurt
Copy link
Collaborator Author

The changes make sense, but seem a bit small in general. Do you really adjust the size of the data container (needs to be dim x ids.size() in the vector valued case.) and do where does the isVector comes from?

I thought I have added those ones when I add vector support for the VTK file but somehow missing. Data container adjusted when reading input in mesh.cpp mesh.data.reserve(NumPoints * dim); . isVector() is coming from the command-line argument.

@fsimonis fsimonis self-requested a review October 11, 2021 13:31
Copy link
Member

@fsimonis fsimonis left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Short and readable.
I like it 👍

@davidscn davidscn merged commit acb4ffc into precice:migrate-vtk Oct 11, 2021
@kursatyurt kursatyurt deleted the feature-preCICEVectorSupport branch October 11, 2021 16:00
davidscn pushed a commit that referenced this pull request Nov 22, 2021
* Add vector support for preCICE interface

* Add asserttions for reading and writing blocks
davidscn added a commit that referenced this pull request Nov 24, 2021
* Support for reading VTK file format (#26)

* Add VTK library to CMakeList

* Add support for specify data name and add support for reading from VTK files

* Add switch for vector data

* Add warning for VTK version to CMakelist

* Change empty dataname information output from clog to cout

* Change explanation for --vector flag

* Add runtime error if number of components and dimension does not match

* Corrected error message

* Change vector checking to more readable one

* Ensure mesh data vector is empty before fill it

* Throw runtime error if dimensions does not match

* Pass dataname as an argument for clear code

* Fix bad syntax and format document

* Revert pointers instead of smartpointers

* Support for Connectivity Information and VTK format Output (#27)

* Add header files required for VTK support

* Add support for reading connectivity

* Add support for VTK output inc. connectivity

* Make code more readable/clear

* Fix iteration bounds for triangles and edges

* Add quadrilateral support

* Add quad elements to mesh summary

* Add quad element edges to gather_unique_edges method

* Add vector support for preCICE interface (#28)

* Add vector support for preCICE interface

* Add asserttions for reading and writing blocks

* Test Modules for Reading and Writing (#29)

* Add vector support for preCICE interface

* Remove old test files

* Add test executables and tests to CMake

* Collect VTK includes and Remove Duplicates

* Bug Fixes

* Add vector support for preCICE interface

* Remove old test files

* Add test executables and tests to CMake

* Collect VTK includes and Remove Duplicates

* Bug Fixes

* Add mistakenly removed assertions

* Change CMake file for Boost Test

* Convert Read Test to A Boost Unit Test

* Add static_cast to PointId's

* Remove md5sum data

* Change CMake to single test file

* Change read/write test to void functions

* Add test to a main test file

* Ignore vscode directory

* Change from size_t arrays to int array to keep it consistent with preCICE interface

* Add new functionality to safely cast from vtkIDtype to preCICE

* Add VID to mesh

* Correct write test cases

* Adapt VID instead of int type arrays

* Add init and final time and corrrect timesteps

* Add a GitHub CI in order to test and build aste

* Make tests working from any directorty

* Bug Fix for Vector Data Write/Reads

* Fix reading parallel files

* Fix VTK Cmake configuration for VTK version > 8.90.0 (#43)

VTK version higher than 8.9 requires a different CMake configration

* Fix naming convention (#42)

* Obey VTK naming convention

* Fix naming

* Make output prettier, fix spaces

* Update VTK Calc (#39)

* Upgrade VTK Calculator as Standalone Script

* Add input datatag

* Update arguments

* Make intag argument optional

* Change coordinates variables names

* Support vtu and vtk export. Add guard for output meshname.

* Add relative l2 norm error to stats

* Instead of basename use full filename.

* Add additional log informations

* Change difference mode calculation

* Fix output extension bug

* Fix bug and remove abs

* Add explanation

* Clean unused/old scripts (#44)

* Fix Join Mesh (#41)

* Fix Join Mesh.

Reads `vtu` files and join into a `vtu` or `vtk` file.
If recovery file is given preserves original mesh order and cells else appends partition-wise

* Fix grammar for parser help

Co-authored-by: David Schneider <david.schneider@ipvs.uni-stuttgart.de>

* Fix grammar for explaination

Co-authored-by: David Schneider <david.schneider@ipvs.uni-stuttgart.de>

* Fix grammar for explanation

Co-authored-by: David Schneider <david.schneider@ipvs.uni-stuttgart.de>

* Correct language of explanation

* Change help messages

* Add more info to help message

Co-authored-by: David Schneider <david.schneider@ipvs.uni-stuttgart.de>

* Fix Mesh Partitioner  (#40)

* Fix Mesh Partitioner to working with VTK library

Process all PointData. Reduce Recovery file.

* Include size and cell types to recovery info

* Fix bug

* Fix partiton name

* Change Explanations

* Fix readeer types GenericDataObject reader has problem with XML files.

* Fix inserting new tuple to VTK array

* Fix preCICE installation in test

* Fix mesh input explanation

* Change from GenericReader to extension aware reader

* Fix mesh input explanation

* Change from GenericReader to extension aware reader

Co-authored-by: David Schneider <david.schneider@ipvs.uni-stuttgart.de>
davidscn added a commit that referenced this pull request Nov 24, 2021
* Support for reading VTK file format (#26)

* Add VTK library to CMakeList

* Add support for specify data name and add support for reading from VTK files

* Add switch for vector data

* Add warning for VTK version to CMakelist

* Change empty dataname information output from clog to cout

* Change explanation for --vector flag

* Add runtime error if number of components and dimension does not match

* Corrected error message

* Change vector checking to more readable one

* Ensure mesh data vector is empty before fill it

* Throw runtime error if dimensions does not match

* Pass dataname as an argument for clear code

* Fix bad syntax and format document

* Revert pointers instead of smartpointers

* Support for Connectivity Information and VTK format Output (#27)

* Add header files required for VTK support

* Add support for reading connectivity

* Add support for VTK output inc. connectivity

* Make code more readable/clear

* Fix iteration bounds for triangles and edges

* Add quadrilateral support

* Add quad elements to mesh summary

* Add quad element edges to gather_unique_edges method

* Add vector support for preCICE interface (#28)

* Add vector support for preCICE interface

* Add asserttions for reading and writing blocks

* Test Modules for Reading and Writing (#29)

* Add vector support for preCICE interface

* Remove old test files

* Add test executables and tests to CMake

* Collect VTK includes and Remove Duplicates

* Bug Fixes

* Add vector support for preCICE interface

* Remove old test files

* Add test executables and tests to CMake

* Collect VTK includes and Remove Duplicates

* Bug Fixes

* Add mistakenly removed assertions

* Change CMake file for Boost Test

* Convert Read Test to A Boost Unit Test

* Add static_cast to PointId's

* Remove md5sum data

* Change CMake to single test file

* Change read/write test to void functions

* Add test to a main test file

* Ignore vscode directory

* Change from size_t arrays to int array to keep it consistent with preCICE interface

* Add new functionality to safely cast from vtkIDtype to preCICE

* Add VID to mesh

* Correct write test cases

* Adapt VID instead of int type arrays

* Add init and final time and corrrect timesteps

* Add a GitHub CI in order to test and build aste

* Make tests working from any directorty

* Bug Fix for Vector Data Write/Reads

* Fix reading parallel files

* Fix VTK Cmake configuration for VTK version > 8.90.0 (#43)

VTK version higher than 8.9 requires a different CMake configration

* Fix naming convention (#42)

* Obey VTK naming convention

* Fix naming

* Make output prettier, fix spaces

* Update VTK Calc (#39)

* Upgrade VTK Calculator as Standalone Script

* Add input datatag

* Update arguments

* Make intag argument optional

* Change coordinates variables names

* Support vtu and vtk export. Add guard for output meshname.

* Add relative l2 norm error to stats

* Instead of basename use full filename.

* Add additional log informations

* Change difference mode calculation

* Fix output extension bug

* Fix bug and remove abs

* Add explanation

* Clean unused/old scripts (#44)

* Fix Join Mesh (#41)

* Fix Join Mesh.

Reads `vtu` files and join into a `vtu` or `vtk` file.
If recovery file is given preserves original mesh order and cells else appends partition-wise

* Fix grammar for parser help

Co-authored-by: David Schneider <david.schneider@ipvs.uni-stuttgart.de>

* Fix grammar for explaination

Co-authored-by: David Schneider <david.schneider@ipvs.uni-stuttgart.de>

* Fix grammar for explanation

Co-authored-by: David Schneider <david.schneider@ipvs.uni-stuttgart.de>

* Correct language of explanation

* Change help messages

* Add more info to help message

Co-authored-by: David Schneider <david.schneider@ipvs.uni-stuttgart.de>

* Fix Mesh Partitioner  (#40)

* Fix Mesh Partitioner to working with VTK library

Process all PointData. Reduce Recovery file.

* Include size and cell types to recovery info

* Fix bug

* Fix partiton name

* Change Explanations

* Fix readeer types GenericDataObject reader has problem with XML files.

* Fix inserting new tuple to VTK array

* Fix preCICE installation in test

* Fix bug intag is not used if it is given

* Fix bug intag is not used if it is given

Co-authored-by: David Schneider <david.schneider@ipvs.uni-stuttgart.de>
@davidscn davidscn mentioned this pull request Sep 19, 2022
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.

3 participants