program s2fil_localisation_thres ! Uses use s2_types_mod use s2_vect_mod use s2fil_types_mod use s2fil_error_mod use s2fil_field_mod ! Calls call parse_options call s2_vect_convert call s2_vect_free call s2fil_error call s2fil_field_free call s2fil_field_get_scale_val call s2fil_field_loc_thres ! Variables integer, parameter :: MIN_REG_SIZE = 50 integer, parameter :: S2FIL_RECLASS_SIZ = 1 integer, parameter :: S2FIL_RECLASS_VAL = 2 integer, parameter :: S2FIL_RECLASS_HEU = 3 integer :: reclass_strategy = S2FIL_RECLASS_SIZ character (len=S2_STRING_LEN) :: filename_field character (len=S2_STRING_LEN) :: filename_filter character (len=S2_STRING_LEN) :: filename_out character (len=S2_STRING_LEN) :: filename_thres character (len=S2_STRING_LEN) :: filename_connected logical :: save_thres = .false. logical :: save_connected = .false. type (s2fil_field) :: field real (kind=s2_sp), allocatable, dimension (:,:) :: max_val integer, allocatable, dimension (:,:,:) :: max_loc integer, allocatable, dimension (:,:) :: max_siz integer, allocatable, dimension (:) :: n_regions real (kind=s2_sp) :: nsigma = 3.0e0 integer :: i_reg integer :: i_gamma0 integer :: irp integer :: igp integer :: fail = 0 integer :: n_alpha integer :: n_beta integer :: n_gamma logical :: no_gamma_search = .false. logical, allocatable, dimension (:,:) :: keep real (kind=s2_sp) :: ANG_EXTEND_SIZE = 1.0e0 real (kind=s2_sp), dimension (1:S2FIL_SCALE_DIM2_SIZE) :: dil real (kind=s2_sp) :: alpha real (kind=s2_sp) :: beta real (kind=s2_sp) :: alpha_p real (kind=s2_sp) :: beta_p type (s2_vect) :: v type (s2_vect) :: vp real (kind=s2_sp) :: dist real (kind=s2_sp) :: dist_near real (kind=s2_sp) :: dot integer :: n_keep integer :: i_keep character, parameter :: COMMENT_CHAR = '#' integer :: fileid = 21 ! Subroutines and functions subroutine parse_options () end program s2fil_localisation_thresFind localised regions in filtered field using thresholding strategy. Locations and values found are written to the standard output.
Usage: s2fil_localisation_thres
Author: J. D. McEwen (mcewen@mrao.cam.ac.uk)
Version: 0.1 - April 2005
integer, parameter :: MIN_REG_SIZE = 50
integer, parameter :: S2FIL_RECLASS_SIZ = 1
integer, parameter :: S2FIL_RECLASS_VAL = 2
integer, parameter :: S2FIL_RECLASS_HEU = 3
integer :: reclass_strategy = S2FIL_RECLASS_SIZ
character (len=S2_STRING_LEN) :: filename_field
character (len=S2_STRING_LEN) :: filename_filter
character (len=S2_STRING_LEN) :: filename_out
character (len=S2_STRING_LEN) :: filename_thres
character (len=S2_STRING_LEN) :: filename_connected
logical :: save_thres = .false.
logical :: save_connected = .false.
type (s2fil_field) :: field
real (kind=s2_sp), allocatable, dimension (:,:) :: max_val
integer, allocatable, dimension (:,:,:) :: max_loc
integer, allocatable, dimension (:,:) :: max_siz
integer, allocatable, dimension (:) :: n_regions
real (kind=s2_sp) :: nsigma = 3.0e0
integer :: i_reg
integer :: i_gamma0
integer :: irp
integer :: igp
integer :: fail = 0
integer :: n_alpha
integer :: n_beta
integer :: n_gamma
logical :: no_gamma_search = .false.
logical, allocatable, dimension (:,:) :: keep
real (kind=s2_sp) :: ANG_EXTEND_SIZE = 1.0e0
real (kind=s2_sp), dimension (1:S2FIL_SCALE_DIM2_SIZE) :: dil
real (kind=s2_sp) :: alpha
real (kind=s2_sp) :: beta
real (kind=s2_sp) :: alpha_p
real (kind=s2_sp) :: beta_p
type (s2_vect) :: v
type (s2_vect) :: vp
real (kind=s2_sp) :: dist
real (kind=s2_sp) :: dist_near
real (kind=s2_sp) :: dot
integer :: n_keep
integer :: i_keep
character, parameter :: COMMENT_CHAR = '#'
integer :: fileid = 21
subroutine parse_options () ! Calls: getArgument end subroutine parse_optionsParse the options passed when program called.
Author: J. D. McEwen (mcewen@mrao.cam.ac.uk)
Version: 0.1 - February 2005