Home > SaliencyToolbox > defaultSaliencyParams.m

defaultSaliencyParams

PURPOSE ^

defaultSaliencyParams - returns a default salParams structure.

SYNOPSIS ^

function params = defaultSaliencyParams(varargin)

DESCRIPTION ^

 defaultSaliencyParams - returns a default salParams structure.

 params = defaultSaliencyParams
    Returns a default structure with saliency parameters.

 params = defaultSaliencyParams(pyramidType)
    Initializes parameters for a particular pyramidType:
       'dyadic' - pyramids with downsampling by a factor of 2 (default)
       'sqrt2'  - pyramids with downsampling by a factor of sqrt(2)
    This makes a difference for the levels for the computation of the
    center-surround differences.

 params = defaultSaliencyParams(...,imgSize)
    Initializes params.foaSize to 1/6*min(w,h) (default: -1).
    This is only important for params.IORtype='disk'.

 See also runSaliency, makeSaliencyMap, estimateShape, applyIOR,
          removeColorFeatures, winnerToImgCoords, dataStructures.

CROSS-REFERENCE INFORMATION ^

This function calls: This function is called by:

SOURCE CODE ^

0001 % defaultSaliencyParams - returns a default salParams structure.
0002 %
0003 % params = defaultSaliencyParams
0004 %    Returns a default structure with saliency parameters.
0005 %
0006 % params = defaultSaliencyParams(pyramidType)
0007 %    Initializes parameters for a particular pyramidType:
0008 %       'dyadic' - pyramids with downsampling by a factor of 2 (default)
0009 %       'sqrt2'  - pyramids with downsampling by a factor of sqrt(2)
0010 %    This makes a difference for the levels for the computation of the
0011 %    center-surround differences.
0012 %
0013 % params = defaultSaliencyParams(...,imgSize)
0014 %    Initializes params.foaSize to 1/6*min(w,h) (default: -1).
0015 %    This is only important for params.IORtype='disk'.
0016 %
0017 % See also runSaliency, makeSaliencyMap, estimateShape, applyIOR,
0018 %          removeColorFeatures, winnerToImgCoords, dataStructures.
0019 
0020 % This file is part of the SaliencyToolbox - Copyright (C) 2006-2013
0021 % by Dirk B. Walther and the California Institute of Technology.
0022 % See the enclosed LICENSE.TXT document for the license agreement.
0023 % More information about this project is available at:
0024 % http://www.saliencytoolbox.net
0025 
0026 function params = defaultSaliencyParams(varargin)
0027 
0028 % this is only important for IORtype='disk'.
0029 params.foaSize = -1;
0030 
0031 % one of: 'dyadic','sqrt2'
0032 params.pyramidType = 'dyadic';
0033 
0034 % scan the arguments
0035 for i = 1:length(varargin)
0036   switch class(varargin{i})
0037     case 'double'
0038       params.foaSize = round(max(varargin{i}(1:2)) / 6);
0039     case 'char'
0040       params.pyramidType = varargin{i};
0041     otherwise
0042       error(['Unknown data type for this function: ' class(varargin{i})]);
0043   end
0044 end
0045 
0046 % a cell array with a combination of:
0047 % 'Color','Intensities','Orientations','Hue','Skin','TopDown'
0048 params.features = {'Color','Intensities','Orientations'};
0049 
0050 % the weights in the same order as params.features
0051 params.weights = [1 1 1];
0052 
0053 % one of: 'shape','disk','None'
0054 params.IORtype = 'shape';
0055 
0056 % one of: 'None','shapeSM','shapeCM','shapeFM','shapePyr'
0057 %params.shapeMode = 'shapePyr';
0058 params.shapeMode = 'shapeFM';
0059 
0060 % the pyramid level parameters
0061 params.levelParams = defaultLevelParams(params.pyramidType);
0062 
0063 % one of: 'None','LocalMax','Iterative'
0064 params.normtype = 'Iterative';
0065 
0066 % number of iterations for Iterative normalization
0067 params.numIter = 3;
0068 
0069 % 1 for using random jitter in converting from saliency map
0070 %   coordinates to image coordinates,
0071 % 0 for not using random jitter
0072 params.useRandom = 1;
0073 
0074 % one of: 'Fast','LTU'
0075 params.segmentComputeType = 'Fast';
0076 
0077 params.IORdecay = 0.9999;
0078 params.smOutputRange = 1e-9;
0079 params.noiseAmpl = 1e-17;
0080 params.noiseConst = 1e-14;
0081 
0082 % parameters for the gabor filters for orientation maps
0083 params.gaborParams = defaultGaborParams;
0084 
0085 % angles (in degrees) for orientation maps
0086 params.oriAngles = [0 45 90 135];
0087 
0088 % oriComputeMode: 'efficient', 'full'
0089 % efficient: only compute orientation filters for the pyramid levels
0090 % that are actually going to be used (based on levelParams)
0091 % full: compute orientation filters for all pyramid levels
0092 params.oriComputeMode = 'efficient';
0093 
0094 % visualizationMode: 'Contour', 'ContrastModulate', or 'None'
0095 params.visualizationStyle = 'Contour';
0096 
0097 % map that is true foer excluded regions
0098 params.exclusionMask = [];

Generated on Thu 18-Jul-2013 06:10:46 by m2html © 2005