function configurationFile(img, depthMap) % Version 0.1, Feb 2006. % This code is copyrighted by Ashutosh Saxena, Stanford University % It is available for non-commercial use only. For commericial use, please % contact the authors. % Any publication or report resulting from Use of this code, should cite: % Learning Depth from Single Monocular Images, Ashutosh Saxena, Sung H. Chung, Andrew Y. Ng, NIPS 2005. % 3-D Depth Reconstruction from a Single Still Image, Ashutosh Saxena, Sung H. Chung, Andrew Y. Ng, To appear in IJCV 2007. % For more info and dataset, visit: http://ai.stanford.edu/~asaxena/learningdepth/ % For a better version of the algorithm, also visit: % http://ai.stanford.edu/~asaxena/reconstruction3d/ global nGridCol nGridRow global columnWidth rowWidth %global scale2Factor global imageDirectory depthMapDirectory featureDirectory relativeFeatureDirectory imageDirectory2; global maxDistance minDistance global nThetaPrior global nDim nLaw nHarris nDimRel global nStatistics global nThetaStep if nargin < 1 nGridCol = 86; %79; nGridRow = 107;%51; M = 1704;%1694; N = 2272; else M = size(img,1); N = size(img,2); nGridRow = size(depthMap, 1); nGridCol = size(depthMap, 2); end %columnWidth = N/nGridCol %rowWidth = M/nGridRow %scale2Factor = 4; nThetaPrior = 17;%ceil(nGridRow/10); %imageDirectory = '~/scratch/LaserImage2DData/'; %depthMapDirectory = 'depthMapData/'; %imageDirectory = '~/scratch/LaserImage2DData/Dataset2_Images/'; %depthMapDirectory = '~/scratch/LaserImage2DData/depthMapData2Trans/'; %imageDirectory = '~/scratch/LaserImage2DData/Dataset3_Images/'; imageDirectory = '~/www/learningdepth/Data/Dataset3_Images/Dataset3_Images/'; %imageDirectory2 = '~/scratch/LaserImage2DData/Dataset2_Images/'; %depthMapDirectory = '~/scratch/LaserImage2DData/depthMapData3/'; depthMapDirectory = '/afs/cs.stanford.edu/u/asaxena/www/learningdepth/Data/tmpDepthExtractor/depthMapData3/'; %featureDirectory = '/afs/cs.stanford.edu/u/asaxena/scratch/LaserImage2DData/savedMatFilesFeature/'; %featureDirectory = '/tmp/codedeft/'; %featureDirectory = '/tmp/Ashutosh/'; %featureDirectory = '/export/sc1/codedeft/'; %featureDirectory = '/export/sc1/3d/codedeft/'; relativeFeatureDirectory = '/tmp/codedeft/'; %featureDirectory = '/export/sc1/3d/codedeft/'; featureDirectory = '/tmp/Ashutosh/'; nLaw = 17; nHarris = 0; nStatistics = 3; %1 for H2 only nDim = nStatistics*(nLaw + nHarris); nDimRel = 170; nThetaStep = 2; maxDistance = log(81.91); minDistance = log(.9);