function createTrainingSet(featureType, nDataSet, filename, graphicsSelection)
% Copyright: Ashutosh Saxena, Stanford University
% http://ai.stanford.edu/~asaxena/learningdepth/data.html
% http://ai.stanford.edu/~asaxena/rccar/
%
% This file lists the good parts in the data.

%Field 1: 145 to 470
%then calibration
%Field 2: 710 to 1149
%then Field 3
%then return back through man-made structures

global directoryPath

if nargin < 1
featureType = 'purelaws';
end
if nargin < 2
nDataSet = [1 2];
end
if nargin < 3
filename = '';
end
if nargin < 4
graphicsSelection = 5;
end

%[directoryPath filename featureType '1.mat']
warning off;
if sum(nDataSet == 1)
%createFeatureVectorMatchedToRange(dataset, imageIndex, makeMovieFlag, saveFilename, featureVectorType)
disp('Set 1');
disp([1 ...
createFeatureVectorMatchedToRange('laser1', [145 470], 0, [directoryPath filename featureType '1.mat'], featureType) ]);
disp([2 ...
createFeatureVectorMatchedToRange('laser1', [710 1149], 0, [directoryPath filename featureType '2.mat'], featureType) ]);
disp([3 ...
createFeatureVectorMatchedToRange('laser1', [1163 1380], 0, [directoryPath filename featureType '3.mat'], featureType) ]);
end
if sum(nDataSet == 2)
disp('Set 2')
disp([4 ...
createFeatureVectorMatchedToRange('laser2', [9 589], 0, [directoryPath filename featureType '4.mat'], featureType) ]);
disp([5 ...
createFeatureVectorMatchedToRange('laser2', [661 1621], 0, [directoryPath filename featureType '5.mat'], featureType) ]);
disp([6 ...
createFeatureVectorMatchedToRange('laser2', [1622 2801], 0, [directoryPath filename featureType '6.mat'], featureType) ]);
disp([7 ...
createFeatureVectorMatchedToRange('laser2', [2926 3156], 0, [directoryPath filename featureType '7.mat'], featureType) ]);
disp([8 ...
createFeatureVectorMatchedToRange('laser2', [3508 3668], 0, [directoryPath filename featureType '8.mat'], featureType) ]);
disp([9 ...
createFeatureVectorMatchedToRange('laser2', [4703 5123], 0, [directoryPath filename featureType '9.mat'], featureType) ]);
disp([10 ...
createFeatureVectorMatchedToRange('laser2', [5323 6603], 0, [directoryPath filename featureType '10.mat'], featureType) ]);
% 'good'
disp([11 ...
createFeatureVectorMatchedToRange('laser2', [6653 7833], 0, [directoryPath filename featureType '11.mat'], featureType) ]);

disp([12 ...
createFeatureVectorMatchedToRange('laser2', [8553 8578], 0, [directoryPath filename featureType '12.mat'], featureType) ]);

%white trees
disp([13 ...
createFeatureVectorMatchedToRange('laser2', [9453 9883], 0, [directoryPath filename featureType '13.mat'], featureType) ]);

disp([14 ...
createFeatureVectorMatchedToRange('laser2', [11183 11853], 0, [directoryPath filename featureType '14.mat'], featureType) ]);
disp([15 ...
createFeatureVectorMatchedToRange('laser2', [12003 12053], 0, [directoryPath filename featureType '15.mat'], featureType) ]);
disp([16 ...
createFeatureVectorMatchedToRange('laser2', [12573 12700], 0, [directoryPath filename featureType '16.mat'], featureType) ]);
end
if sum(nDataSet == 3)
disp('Graphics');
for n=graphicsSelection
disp(16+n);
%createFeatureVectorMatchedToRange(['graphics' num2str(n)], [3 1002], 0, [directoryPath filename featureType num2str(n+16) '.mat'], featureType);
createFeatureVectorMatchedToRange('graphics10', [3 1002], 0, '~/scratch/savedMatFiles/laws26.mat', 'laws');
end
end

warning on;
return;