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

Allow heterogenous cell data types? #9

Open
CrashBurnRepeat opened this issue Mar 14, 2018 · 3 comments
Open

Allow heterogenous cell data types? #9

CrashBurnRepeat opened this issue Mar 14, 2018 · 3 comments

Comments

@CrashBurnRepeat
Copy link

I've been implementing my own version of Dual Contouring (http://faculty.cs.tamu.edu/schaefer/research/dualcontour.pdf) and I noticed that if all the cell data types returned by refine_data are not identical, then split! fails because the child data gets returned as Tuple{Tuple{...}} instead of just Tuple{...}. Having this ability could be useful to leverage multiple dispatch on the cell data, as well as making the package easier to experiment with. Is there a reason the types need to be identical, or might this even be a bug?

@rdeits
Copy link
Collaborator

rdeits commented Mar 15, 2018

Ah, that sounds like a bug. Do you have some code that you can share to reproduce the error?

I would be somewhat concerned that having heterogeneous data types in each cell could hurt performance, since you'll be doing run-time method dispatch, but it still should at least work.

@CrashBurnRepeat
Copy link
Author

Sure, I'll see if I can come up with a more simple to work with example.

For my case, it might be useful to have different types for cells that are inside/outside/spanning surfaces to limit the amount of checking I have to do manually. Maybe there's a more elegant solution to this though.

@ashwani-rathee
Copy link

Is there a case to be made for heterogenous data types in each cell? It won't be the hardest thing to be implement but again the question of performance and these tree can become really big ;-;

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

No branches or pull requests

3 participants