Add console app for running isolated benchmarks #32
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 adds a console app to the project that can run benchmarks outside of Rhino/GH over a set number of iterations. It does so by mocking parameters within the SandWorm component that are necessary to simulate acting on a mesh. The idea here is to be able to easily A/B changes without running Rhino/Grasshopper and to measure performance more reliably.
Currently this relates to #29 and #30 so the test functions and overall classes are setup to test the mesh coloring stage. If it is useful for optimising other parts of the code it should be able to be extended to cover different mock data/methods and the amount of mock data setup could be reduce by creating a shared class that is inherited by both
SandwormComponent
andMockMesh
.I'm a little split as to whether this should be in the main repo or kept on a branch. The former is a bit less clean, but is more convenient. If it proves useful it would also be easier to be able to improve the console app itself along the rest of the code. We could also just remove it later if it ends up being less useful?
Also a result of this, the console app needs to reference a
Sandworm.dll
so Sandworm needs to be built first (ideally as the released build) and the 'erase' step of the build event has been removed.