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

fix #5034. Apply Vector Field Node performance proposal solution #5035

Merged
merged 3 commits into from
Oct 29, 2023

Conversation

satabol
Copy link
Collaborator

@satabol satabol commented Oct 28, 2023

fix #5034. Apply Vector Field Node performance proposal solution

In general 9356ms to 582ms is 16 times. (refactor to numpy)

image

Example in real time: (on my computer)

fix_5034_Apply_Vector_Field_Node_performance_proposal edit 002

File for tests:
fix_5034_Apply_Vector_Field_Node_performance_proposal.v001_51160_autosave.blend.zip

P.S.
Comment to the future: If refactor some spline's library functions one can do more performance. I think this code can be optimized too:
image

@satabol
Copy link
Collaborator Author

satabol commented Oct 28, 2023

Hi @portnov.

Can you review this solution?

@portnov
Copy link
Collaborator

portnov commented Oct 29, 2023

What about other SvSurface implementations?

@satabol
Copy link
Collaborator Author

satabol commented Oct 29, 2023

I did not know about this class. Do you have a plan for this class?

@portnov
Copy link
Collaborator

portnov commented Oct 29, 2023

You can try to write generic implementation of your method in base SvSurface class. Maybe it is possible to do it efficiently. Other possible solution is to implement it in each SvSurface implementation, with specific optimizations in each class; but that would be some amount of work.

…3. Escape calculation of vertices by polimorphizm. Some 'normal_array' of surface calcs source vertices so there is no need calc vertices by evaluate_array. So written function 'normal_vertices_array' is SvSurface and in some inheritance classes that return both params if needed.
Copy link
Collaborator

@portnov portnov left a comment

Choose a reason for hiding this comment

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

looks good now.

@satabol
Copy link
Collaborator Author

satabol commented Oct 29, 2023

@portnov Thank you!

@satabol satabol merged commit 8e19ef8 into master Oct 29, 2023
1 check passed
@satabol satabol deleted the fix_5034_Apply_Vector_Field_Node_performance_proposal branch October 29, 2023 16:04
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.

Apply Vector Field Node performance proposal
2 participants