Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This PR makes a few changes to
ansys.dpf.core.plotter.Plotter. Some keyword arguments were added, along with some performance improvements when mapping an individual field to the global data array.Previously, we had:
This works quite well since python dictionaries (
m_id_to_index) are quite fast. However, we can do a bit better by implementing amapandget, since those are implemented in C. Locally, this results in a 3x speedup in this section of code, which can be quite significant considering that it takes around ~60 ms prior to optimization for a 70k node model. For a 1M node model, estimated time savings for this method is around 570 ms.New implementation is: