function selected_points = demo3DDiffeoPick(numimgs,data_points)
% function [ output_args ] = demo3DDiffeoSynth( input_args )
%This demo illustrates different ways to sample from points in a
%diffeomorphic model.
%
%Note, this will only work if you have display capabilities (not command line). 
%
%D. Sullivan 4/23/14

%If the number of image isn't specified let's go with 5. 
if nargin<1
    numimgs = 5;
end

if nargin>1
figure,scatter(data_points(:,1),data_points(:,2))
hold on
end

%pre-allocate 
selected_points = zeros(numimgs,2);

%loop through the images and let the user pick them
naninds = [];
for i = 1:numimgs
    [selected_points(i,1),selected_points(i,2)] = ginput(1);
    scatter(selected_points(i,1),selected_points(i,2),40,'.g');
    
end

% imgs = model2img({model}, param);
