-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathexample.m
executable file
·29 lines (23 loc) · 1.63 KB
/
example.m
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
% This script launches a distortion analysis based on two sets of ground control points
% Written by Manuel Claeys Bouuaert, 2015
clear
if(~isdeployed)
addpath(genpath('.'))
end
% Load ground control points
points = dlmread('data_sample/points.txt')';
gcps_d = points(4:5,:); % points in the 'domain'
gcps_c = points(2:3,:); % points in the 'codomain'
% Set preferences
spatRes_d = 500; % Spatial Resolution in the domain when creating mesh. 500 for sample data
spatBuffer_d = 8000; % Spatial buffer for mesh in the codomain. 8000 for sample data
spatResType = 'absolute'; % Are spatRes_d and spatBuffer_d input 'absolute' or 'relative' numbers (see how those are treated in distortionAnalysis)
scalingReference = 'helmert'; % Should reference value be used for a, b, sigma: 'helmert' (use value of helmert scaling as reference) or 'none' (don't use reference value)
doDisplacementVectors = 1; % Should warped grid be written out?
doDistortionGrid = 1; % Should warped grid be written out?
doDifferentialDistortionAnalysis = 1; % Should Differential Distortion Analysis be written out?
doIndicatrices = 1; % Should Tissot indicators be written out?
doPlots = 0; % Should plots be made?
% Perform analysis
% distortionAnalysis(gcps_d,gcps_c) % Simplest call to distortionAnalysis.m. Default values specified in distortionAnalysis.m will be used in stead of used defined preferences.
distortionAnalysis(gcps_d,gcps_c,spatRes_d,spatBuffer_d,spatResType,scalingReference,doDisplacementVectors,doDistortionGrid,doDifferentialDistortionAnalysis,doIndicatrices,doPlots)