Ticket #3197 (closed: fixed)

Opened 9 years ago

Last modified 5 years ago

Create a 2D rebinning algorithm

Reported by: Martyn Gigg Owned by: Martyn Gigg
Priority: major Milestone: Iteration 30
Component: Mantid Keywords:
Cc: Blocked By:
Blocking: Tester: Stuart Campbell

Description


Change History

comment:1 Changed 9 years ago by Martyn Gigg

(In [12639]) Add a Vertex and ConvexPolygon class to aid in 2D rebinning. Re #3197

comment:2 Changed 9 years ago by Martyn Gigg

(In [12641]) Fix for exception include. Why does MSVC let this compile? Re #3197

comment:3 Changed 9 years ago by Martyn Gigg

(In [12647]) Add methods for area determination to ConvexPolygon. Refs #3197

comment:4 Changed 9 years ago by Martyn Gigg

(In [12648]) Correction for include (again). Refs #3197

comment:5 Changed 9 years ago by Martyn Gigg

  • Status changed from new to accepted

comment:6 Changed 9 years ago by Martyn Gigg

(In [12664]) Change the implementation of the area method for convex polygon so that it is not as easy to get one of the internal triangles vertex order mixed up. Refs #3197

comment:7 Changed 9 years ago by Martyn Gigg

(In [12719]) Convex polygon intersection code should be working correctly now. Maybe not as efficient as it can be but tests are there and it works. Re #3197

comment:8 Changed 9 years ago by Martyn Gigg

(In [12723]) Extract some code regarding bin creation and put it in NumericAxis. Re #3197

comment:9 Changed 9 years ago by Martyn Gigg

(In [12724]) Checkpoint for Rebin2D. Not included in CMakeLists yet so doesn't build. Re #3197"

comment:10 Changed 9 years ago by Martyn Gigg

(In [12782]) The performance can be improved but Rebin2D should give the correct values with the exception of masked bins at the moment. Re #3197

comment:11 Changed 9 years ago by Martyn Gigg

(In [12786]) I forgot I changed something in Gometry as well. Re #3197

comment:12 Changed 9 years ago by Martyn Gigg

(In [12788]) Imrpove the performance of Rebin2D with a couple of simple checks. Re #3197

comment:13 Changed 9 years ago by Martyn Gigg

(In [12791]) Add a performance test for the polygon intersection code. Re #3197

comment:14 Changed 9 years ago by Martyn Gigg

(In [12795]) Refactor some code in Rebin2D to make handling distibutions easier and clearer. Re #3197

comment:15 Changed 9 years ago by Martyn Gigg

  • Status changed from accepted to verify
  • Resolution set to fixed

It's ready to test. A workspace with a spectra axis will need ConvertSpectrumAxis running first. It should probably be done as part of the algorithm but it is horrendously slow at the moment so I chose not to for the time being.

comment:16 Changed 9 years ago by Wenduo Zhou

  • Status changed from verify to verifying
  • Tester set to Wenduo Zhou

comment:17 Changed 9 years ago by Wenduo Zhou

  • Status changed from verifying to verify
  • Tester Wenduo Zhou deleted

comment:18 Changed 9 years ago by Stuart Campbell

  • Status changed from verify to verifying
  • Tester set to Stuart Campbell

comment:19 Changed 9 years ago by Stuart Campbell

There is no wiki page - created ticket #3268

comment:20 Changed 9 years ago by Stuart Campbell

  • Status changed from verifying to closed

It seems to work, but it is not the most intuitive algorithm at the moment! :-)

comment:21 Changed 9 years ago by Martyn Gigg

  • Status changed from closed to reopened
  • Resolution fixed deleted
  • Milestone changed from Iteration 29 to Iteration 30

Jon Taylor has demonstrated some oddities to me that mean that this isn't quite right yet so lets not broadcast it for the release.

comment:22 Changed 9 years ago by Stuart Campbell

Just a suggestion; but should we close this one under iteration 29 (as this was where the work has been done) and create new tickets for the problems Jon has seen under the next iteration?

comment:23 Changed 9 years ago by Martyn Gigg

  • Status changed from reopened to accepted

comment:24 Changed 9 years ago by Martyn Gigg

(In [12998]) Improve the polygon intersection algorithm from O Rourke by allowing more than integer precision when computing the cross products. Re #3197

comment:25 Changed 9 years ago by Martyn Gigg

(In [13022]) Revert the changes for precision as they are actually not reliable. Re #3197

comment:26 Changed 9 years ago by Martyn Gigg

Following advice from Michael Reuter I'm going to implement the implementation of polygon intersection by M. Laszlo to avoid the precisison problems with the implementation by O Rourke.

I'll close this one and I have created a new ticket, #3341, for this.

comment:27 Changed 9 years ago by Martyn Gigg

  • Status changed from accepted to verify
  • Resolution set to fixed

comment:28 Changed 9 years ago by Owen Arnold

  • Status changed from verify to verifying
  • Tester changed from Stuart Campbell to Owen Arnold

comment:29 Changed 9 years ago by Owen Arnold

  • Status changed from verifying to verify
  • Tester Owen Arnold deleted

Tested using combintation of CreateWorkspace and Rebin2D. No issues. Worth going back to original tester before signing-off.

comment:30 Changed 9 years ago by Stuart Campbell

  • Status changed from verify to verifying
  • Tester set to Stuart Campbell

comment:31 Changed 9 years ago by Stuart Campbell

  • Status changed from verifying to closed

Looks good to me. I basically read in some (BASIS) data, converted to EnergyTransfer, Rebinned, ConvertedSpectrum Axis to Q, then ran Rebin2D...

comment:32 Changed 5 years ago by Stuart Campbell

This ticket has been transferred to github issue 4044

Note: See TracTickets for help on using tickets.