1 / 24

CAOX and the LiCAS RTRS

CAOX and the LiCAS RTRS. Patrick Brockill LiCAS Group 5 Oct, 2010. Outline. General discussion of Caox What can it do? What is it missing? Caox core design How Caox has become a generalised framework Reliance on external libraries and programs

zeheb
Télécharger la présentation

CAOX and the LiCAS RTRS

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. CAOX and the LiCAS RTRS Patrick Brockill LiCAS Group 5 Oct, 2010

  2. Outline • General discussion of Caox • What can it do? What is it missing? • Caox core design • How Caox has become a generalised framework • Reliance on external libraries and programs • Case study: the LiCAS Rapid Tunnel Reference Surveyor (RTRS) • Provides motivation for much of what Caox can do • Importance of including inner constraints • Caox operation • Design matrix analysis • Model verification • Future • Future work on Caox • Integration of Caox into other environments, e.g. S.A.

  3. What is Caox? • A C++ framework of about 200 pgs (so far) for least squares analysis • Solve least-squares problems of the form • and constraints • for X as well as . Note that for our purposes we also require off-diagonal elements of • Designed to call and be called by external libraries • Allows for mathematical rigour • Designed for “calibration” and “operation/reconstruction” problems involving rotations/translations, but generally applicable • Already used in LiCAS, Mona Lisa for calibration • A work in progress

  4. What is Caox missing? • User friendliness for input • A way of graphically inputting the problem • 3D input engine • Measurement input • It's own optimisers and algebra routines (framework) • Can also be seen as a strength • Best optimiser for each problem • Performance depends on optimiser, algebra routines • Direct user intervention can dramatically increase speed and size • Status in commercial products unclear • Possibly supply own, but potentially much work • A user base: interest and motivation • Input from those working in geodesy

  5. Caox Core • At the core, Caox relies on C++ templates for definitions of F(X) and constraints • Disadvantages: • Compilation required • Advantages (amongst others): • Speed (important for external libraries) • Allows us to define F(X) and constraints once yet evaluate in many ways

  6. LS Problems:Mode of Attack Caox has been generalised to include not only our original specific problems, but many more kinds of least square (LS) problems in general • Addresses 3 common aspects, applicable to many problems: • (1) Formulation of the Model • (2) Optimisation • (3) Error Analysis • We focus on (1) and (3) • Simple Gauss-Newton w/line fit for (2) • Add support for calling other optimisers • Most externally available software focuses on (2) and (3) • Rely on publicly available external libraries • Numerical BLAS, LAPACK, etc. • Semi-Symbolic ADOL-C • Symbolic GiNaC

  7. Typical ProblemsConsidered So Far L=F(X) • Measurement apparatus calibration • Element of F(X) large composition of functions (e.g. rotations and translations), 150 pages for one element of F(X) • O(2000) elements of X • Design matrix A=dF/dX frequently relatively dense • Regularity problem: elements of L missing • Measurement apparatus operation: “reconstruction” • Very large O(106) elements in X 150 pgs.

  8. Caox: Research & Planning • Input from (amongst others): DESY Geodesy, DESY Physics, Oxford Mathematics, Oxford Photogrammetry, Oxford Engineering, Oxford Physics • Literature: sometimes back to original geodesy literature in German. • Software planning: • Investigated modellers, modelling languages, optimisers • Keeping in mind, e.g.: • Costs • Irregular measurements • Data input format • Graphical checks • Arbitrary precision: “quick • and dirty” calculations despite • rounding errors, large condition • numbers, near-singular matrices, • e.g.

  9. SM beam internal FSI wall markers external FSI collider component Case Study: RTRS Survey Tunnel Wall Reconstructed tunnel shapes (relative co-ordinates) Source: Armin Reichold

  10. RTRS in Motion

  11. Local RTRS Operation Need to Relate Positions Of Cars: Need To Introduce a Common Object Between Them Our Goal: Determine the best positions for the wall markers which agree with our data "Calibration dance": one car at a time is translated... and rotated (at the same time). Hopefully at some point, X in L=F(X) is uniquely determined Multilateration to Determine Wall Marker “External FSI” Laser line passed through all cars… Then reflected back along itself… But none of these systems determines distance between cars so this must also be measured: “Internal FSI” …But first we have to find the positions/orientations of the internal elements (“Calibration”). Caveat: we can’t just measure this... Then split off and observed. Able to determine some rotations and translations this way. “Laser Straightness Monitor” (LSM) Basic Elements (“Subsystems”): Distance between two points Intersection of a line and a plane Tilt sensor We use gravity, i.e. tilt sensors, to determine some rotational d.f. But this is not enough.

  12. Laser Tracker Aided Calib. Additional observations of the car movements to be used if necessary

  13. Characterising the RTRS Problem • Measurement vector L is a large composite quite non-linear function • We need to a way to verify functional form of F(X) • Equality constraint equations also frequently just as composite, complex • Poor condition number of design matrix • Require careful calculation of derivatives in design matrix • Near “symmetries”, graphically visualised and analysed • Regularity problem in actual data • Inner constraints a must

  14. Multilateration Prototype Four Launches in 2D Plane Observing Randomly Moved Retroreflector {L1,L2,L3,L4}(1) 3 Constraints: Trans.: P1x=P1y=0 Rot.: P2y=0 {L1,L2,L3,L4}(2) ? ? {L1,L2,L3,L4}(N) P4 P3 Q(i) L4 L3 L4 L3 L3 L4 y ? ? ?   L2 L2 L=F(X)  +constraints L2 ? ? L1 L1 L1 • Essentially, looking for X=F-1(L) • In this example, we call this “calibration” • More correctly, we want to minimise the • “objective function” [L-F(X)]2 • Least Squares Optimisation P1 P2 x • And we want the errors on the parameters X

  15. Mulilateration (cont.) Given: P1 …P4 and L1…L4. Find Q. • Another least squares problem • How can we make self-calibratable apparati which make optimal measurements? • What are the weak points in a design? • Smaller problem than previous slide • We call this “Reconstruction” or • “Operation” Q 3 Processes P4 P3 ✓ L3 ✓ L4 • Positions and orientations of optical elements, some of which cannot (or only with much difficulty) be measured directly. • Performed by spatial rotations and translations of apparatus. Calibration Operation Design and Analysis ? L2 • Once positions and orientations of optical elements are known, actually make measurements with the apparatus. • Potentially large • Submatrix of calibration covariance matrix required as input L1 ✓ ✓ P1 P2

  16. Design Matrix Analysis • Conceptually: • Hoberman sphere • Eigen. λ=0, λ≈0 can be disastrous • 3D visualisation very useful • Best avoided in design • stage 15

  17. External FSI Self Calibration • POV: looking at the unit • from the tunnel wall • Wallmarker appears for • observation • Quill positions, blue • dots, position in principle • unknown and not directly • measurable • Wall marker, orange dot, • position also unknown • 6 length observations • from quills to wall • marker  can this • determine all of the • unknown positions? • Perhaps if we took enough measurements in • different wall marker positions, all positions • would be determined (“self calibration”) • No. So also consider • another wallmarker • position

  18. Subsystem Symmetriesin the RTRS • No. There is no unique solution if the blue spheres representing the quills are on a conic section (parabola, hyperbola, circle) • Laser Straightness Monitor (LSM) is also not immune – we require three independent/non-parallel normals to the CCD planes • We could fix this symmetry by including one new distance measurement • All of these symmetries are overcome if we calibrate all subsystems together with the laser tracker included.  • Nevertheless, still represent design weaknesses

  19. Design and Verification • Design • Graphical visualisation of small eigenvectors • Simulation: optimisation, best method • Verification of Model • By initial parameters • Symbolically • Graphically (3D) X Yrun[0_11737].car_ccd_xy[0][1][0] == -(cos(car_ccd_orient_0_1_1)*sin(car_ccd_orient_0_1_2)*(cos(Xrun_0_11737_car_orient_0_0)*sin(Xrun_0_11737_car_orient_0_1)*cos(Xrun_0_11737_car_orient_0_2)+sin(Xrun_0_11737_car_orient_0_0)*sin(Xrun_0_11737_car_orient_0_2))+cos(Xrun_0_11737_car_orient_0_0)*(cos(car_ccd_orient_0_1_0)*sin(car_ccd_orient_0_1_1)*sin(car_ccd_orient_0_1_2)-cos(car_ccd_orient_0_1_2)*sin(car_ccd_orient_0_1_0))*cos(Xrun_0_11737_car_orient_0_1)+(sin(car_ccd_orient_0_1_1)*sin(car_ccd_orient_0_1_0)*sin(car_ccd_orient_0_1_2)+cos(car_ccd_orient_0_1_0)*cos(car_ccd_orient_0_1_2))*(cos(Xrun_0_11737_car_orient_0_0)*sin(Xrun_0_11737_car_orient_0_1)*sin(Xrun_0_11737_car_orient_0_2)-cos(Xrun_0_11737_car_orient_0_2)*sin(Xrun_0_11737_car_orient_0_0)))*((sin(Xrun_0_11737_car_orient_2_2)*((cos(Xrun_0_11737_lsm_mirror_orient_0)^2*cos(Xrun_0_11737_lsm_mirror_orient_1)^2-sin(Xrun_0_11737_lsm_mirror_orient_0)^2*cos(Xrun_0_11737_lsm_mirror_orient_1)^2+sin(Xrun_0_11737_lsm_mirror_orient_1)^2)*(cos(Xrun_0_11737_car_orient_2_2)*sin(Xrun_0_11737_car_orient_2_0)-… Measured F(X) Predicted Scale: 30,000 λ=2.2×10-6 644×330 Matrix

  20. Future Plans for Caox • Software Related • Hook into various optimisers, export to AMPL (A Math. Prog. Lang.) (used by, e.g., mathematicians, scientists), GAMS (Gen. Algebraic Modeling System), etc. Also provide a better default optimiser • Parallel processing: CUDA, OpenCL • 64-bit memory processing (264B=106 TB) [232B=4 GB] • Dependencies already support this • Better visualisation: constraints, 3D: Blender, etc. • Theory Related • Better utilisation of sparsity properties • Particular elements of covariance matrix ΣX • Other objective functions, e.g. F(X,L)=0, rather than a class of these of the form F(X)=L

  21. Caox in Other Environments • Possible integration path in S.A. • Export .C, .h files corresponding to internal S.A. representation • Or work directly on program save files • S.A. graphics engine • Uses • Alternate optimizers • Symbolic representation of F(X), constraints • Scientific publications (various methods for comparison, mathematical rigour) • Exotic changes to F(X) not easily accommodated in S.A. • Block handling of A for large problems • Self-calibration analysis • Report full • Tool for SA developers

  22. Example F(X)

  23. Constraints Additional complications over problems without constraints, but are so important difficult to see how to avoid • Inner constraints • Improving convergence, e.g. quaternions • Define a new to allow, e.g. calc of • We measure x1 x2 x3in RTRS's coordinate system x3 x3-x2 x2 x2-x1 x1 • But we are actually interested in x2-x1 and x3-x2

  24. Constraints • Fixing poorly defined elements of X which contribute to large condition numbers and poor convergence properties, but don’t particularly affect the quantities we are interested in. • Coordinates of internal FSI quill- retroreflector pairs not well determined in transverse directions • We can just fix them to what we like - the overall effect on the accuracy is almost zero if moved correctly

More Related