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

Moving Geometry Sometimes Doesn't work #43

Open
jab0707 opened this issue Sep 3, 2020 · 10 comments
Open

Moving Geometry Sometimes Doesn't work #43

jab0707 opened this issue Sep 3, 2020 · 10 comments

Comments

@jab0707
Copy link

jab0707 commented Sep 3, 2020

The moving geometries functionality (assigning a moving geometry as geom.pts_mv which is a n X (3*m) where n is the nodes and m is the number of different moved geometries) sometimes doesn't work. In the attached files one labeled works.mat has no issue, but the one labeled notWorks.mat has different node numbers and positions but is otherwise structured similarly but does not work. map3d will either refuse to plot it, crash, or plot a highly distorted version of it. I have confirmed that the geometries look appropriate in matlab

data.zip

@jab0707
Copy link
Author

jab0707 commented Sep 3, 2020

I loaded each individual geometry into MAP3d separately and they all look fine, it is only when I assemble them into a moving geometry that I get an issue.

@bryanworthen
Copy link
Contributor

All right, I'll take a look. (I don't remember anybody using moving geometries yet.)

I may not have a chance before tomorrow - can you clarify "different node numbers"? That doesn't mean a variable number of points, does it?

@jab0707
Copy link
Author

jab0707 commented Sep 17, 2020

Sorry for the slow response. By different number of nodes I mean that the second moving geometry is a different geometry altogether with a different number of nodes than the geometry that does not work. However I do know that for the notWorks.mat geometry, if I were to extract any single of the geometries from the series of moving points it would work no problem. It is only when stringing this particular set of geometries together that I get an issue.

I have making fairly extensive use of the moving geometries feature and plan to do so even more going forward. I have enjoyed it so far, despite occasional weird bugs like this.

@bryanworthen
Copy link
Contributor

bryanworthen commented Sep 17, 2020 via email

@jab0707
Copy link
Author

jab0707 commented Sep 17, 2020

I do have data. I have noticed that the moving geometries do not work if there is no data. (That would be awesome if we could have moving geometries that both didn't have data and could change the number of nodes)

But for these examples I sent, the moving geometries internally have the name number of nodes per movement. The difference in number of nodes is between the two example files.

@bryanworthen
Copy link
Contributor

bryanworthen commented Sep 18, 2020

Ok, sorry, read too fast.

Initial assessment/notes:

notWorks:
map3d thinks it is time-based point array, m(cols)=240, n(pts)=300 (timesteps=80)
map3d thinks notworks-data.mat has 240 leads
initial hypothesis: notworks pts_mv is transposed.

@bryanworthen
Copy link
Contributor

And transposing it correctly looks like this:

image

@bryanworthen
Copy link
Contributor

bryanworthen commented Sep 22, 2020 via email

@jab0707
Copy link
Author

jab0707 commented Jan 25, 2021

Sorry for the long delay. It looks like transposing does fix the issue. I was under the impression that the .pts_mv field had to be arranged in a m X nt matrix where m is the number of nodes, n is 3 (x,y,z coordinates) and t is the number of time instances. Then each grouping of three columns would be a single geometry for a given time instant. I have had that format work in some cases and not others. (Transposing of course would just flip that convention to be a nt X m matrix). Is there a reliable format to not need to have to transpose back and forth?

@bryanworthen
Copy link
Contributor

bryanworthen commented Feb 11, 2021 via email

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

2 participants