Comparing two sets of coordinates
이전 댓글 표시
Hello
I have two different datasets from two particle scans of a silicon wafer. Each dataset contains a number of x- and y-coordinates from particles found on the wafer. I now want to compare the pre dataset with the post dataset, and see if there are two particles that lie very close (within 30 um) and therefore must be the same.
Right now I am basically comparing each of the points from the pre measurment with all the points from the post measurement and see if any match. However, each dataset can contain several thousands of coordinates, which tend to make the process somewhat slow. Any suggestions on how to make this faster and smarter?
Kind regards Martin
댓글 수: 1
Jan
2011년 10월 18일
Several thousands does not sound as a very large problem. Please post the code you are using - otherwise suggestions for improvements are impossible. Wild guessing does help usually but increase the level of confusion only.
채택된 답변
추가 답변 (1개)
Martin
2011년 10월 19일
0 개 추천
댓글 수: 2
Matt Tearle
2011년 10월 19일
Note to *everyone*: preallocate memory!
Thanks, Martin, for providing a perfect example of why: speedup factor = 167!
Daniel Shub
2011년 10월 19일
I would be curious what version of MATLAB this is in. I thought since r2011a that the cost of not preallocating was greatly reduced. Not to say that you shouldn't when you can, just curious if it is still problematic.
카테고리
도움말 센터 및 File Exchange에서 Programming에 대해 자세히 알아보기
제품
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!