Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
Noah Sennett
lalsuite-archive
Commits
d50a53ab
Commit
d50a53ab
authored
Feb 10, 2006
by
patrick
Browse files
adding the fix discussed with steve to the bugfix branch
parent
b4af7c0e
Changes
1
Hide whitespace changes
Inline
Side-by-side
lalapps/src/inspiral/thinca.c
View file @
d50a53ab
...
...
@@ -254,7 +254,7 @@ int main( int argc, char *argv[] )
REAL4
alphaFhi
=
-
2.e4
;
REAL4
alphaFlo
=
9.e4
;
REAL4
thresholdT
=
1e6
;
REAL4
snrCut
=
0
.
;
REAL4
lambda
=
1e6
;
const
CHAR
ifoList
[
LAL_NUM_IFO
][
LIGOMETA_IFO_MAX
]
=
{
"G1"
,
"H1"
,
"H2"
,
"L1"
,
"T1"
,
"V1"
};
...
...
@@ -332,8 +332,8 @@ int main( int argc, char *argv[] )
{
"maximization-interval"
,
required_argument
,
0
,
'@'
},
{
"alphaF-hi"
,
required_argument
,
0
,
'j'
},
{
"alphaF-lo"
,
required_argument
,
0
,
'l'
},
{
"alpha
f
-snr"
,
required_argument
,
0
,
'v'
},
{
"snr-
threshold
"
,
required_argument
,
0
,
'
*
'
},
{
"alpha
F
-snr"
,
required_argument
,
0
,
'v'
},
{
"snr-
max-ratio
"
,
required_argument
,
0
,
'
u
'
},
{
"data-type"
,
required_argument
,
0
,
'k'
},
{
"comment"
,
required_argument
,
0
,
'x'
},
{
"user-tag"
,
required_argument
,
0
,
'Z'
},
...
...
@@ -399,7 +399,7 @@ int main( int argc, char *argv[] )
c
=
getopt_long_only
(
argc
,
argv
,
"A:B:C:D:E:F:G:H:I:J:K:L:M:N:O:P:Q:R:S:T:U:VW:Y:Z:"
"a:b:c:d:e:f:g:hi:j:k:l:m:n:o:p:q:r:s:t:u:v:w:x:y:z:"
"2:3:4:5:6:7:8:9:!:-:+:=:@:^:&:
*
"
,
"2:3:4:5:6:7:8:9:!:-:+:=:@:^:&:"
,
long_options
,
&
option_index
);
/* detect the end of the options */
...
...
@@ -760,11 +760,6 @@ int main( int argc, char *argv[] )
thresholdT
=
atof
(
optarg
);
ADD_PROCESS_PARAM
(
"float"
,
"%s"
,
optarg
);
break
;
case
'*'
:
snrCut
=
atof
(
optarg
);
ADD_PROCESS_PARAM
(
"float"
,
"%s"
,
optarg
);
break
;
case
'j'
:
/* upper alphaF cutoff */
...
...
@@ -778,6 +773,12 @@ int main( int argc, char *argv[] )
ADD_PROCESS_PARAM
(
"float"
,
"%s"
,
optarg
);
break
;
case
'u'
:
/* lambda of the BCVC veto */
lambda
=
atof
(
optarg
);
ADD_PROCESS_PARAM
(
"float"
,
"%s"
,
optarg
);
break
;
case
'k'
:
/* type of data to analyze */
...
...
@@ -1243,28 +1244,20 @@ int main( int argc, char *argv[] )
alphaFhi
,
alphaFlo
),
&
status
);
}
/*
* for the case of BCVC, discard the triggers that
* have alphaF/SNR greater than thresholdT and alphaF greater than
* alphaFhi or lower than alphaFlo,
* as those are specified in the command line.
*/
if
(
doBCVCVeto
)
{
if
(
vrbflg
)
fprintf
(
stdout
,
"Discarding triggers with snr < %f
\n
"
,
snrCut
);
LAL_CALL
(
LALSNRCutSingleInspiral
(
&
status
,
&
(
inspiralEventList
),
snrCut
),
&
status
);
if
(
lambda
<=
0
)
{
fprintf
(
stderr
,
"Error: snr-max-ratio must be gre greater than zero.
\n
"
);
exit
(
1
);
}
if
(
vrbflg
)
fprintf
(
stdout
,
"Discarding triggers with alphaF > %f OR alphaF < %f
\n
and triggers with |alphaF/snr| >%f
\n
"
,
alphaFhi
,
alphaFlo
,
thresholdT
);
LAL_CALL
(
LALBCVCVetoSingleInspiral
(
&
status
,
&
(
inspiralEventList
),
"Discarding triggers with alphaF > %f OR alphaF < %f
\n
and triggers with rhoU/rhoC > %f or |alphaF./snr|>.15%f
\n
"
,
alphaFhi
,
alphaFlo
,
lambda
,
thresholdT
);
LAL_CALL
(
LALBCVCVetoSingleInspiral
(
&
status
,
&
(
inspiralEventList
),
lambda
,
alphaFhi
,
alphaFlo
,
thresholdT
),
&
status
);
}
/* maximize over a given interval */
if
(
maximizationInterval
)
...
...
@@ -1408,20 +1401,9 @@ int main( int argc, char *argv[] )
LAL_CALL
(
LALCreateTwoIFOCoincList
(
&
status
,
&
coincInspiralList
,
inspiralEventList
,
&
accuracyParams
),
&
status
);
if
(
distCut
)
if
(
distCut
)
{
if
(
!
doBCVCVeto
)
{
XLALInspiralDistanceCut
(
&
coincInspiralList
,
&
accuracyParams
);
}
else
{
if
(
vrbflg
)
fprintf
(
stdout
,
"Discarding triggers h1-h2-distance-cut using kappa=%f and epsilon = %f
\n
"
,
accuracyParams
.
ifoAccuracy
[
LAL_IFO_H1
].
kappa
,
accuracyParams
.
ifoAccuracy
[
LAL_IFO_H1
].
epsilon
);
XLALInspiralDistanceCutBCVC
(
&
coincInspiralList
,
&
accuracyParams
);
}
XLALInspiralDistanceCut
(
&
coincInspiralList
,
&
accuracyParams
);
}
...
...
@@ -1511,21 +1493,10 @@ int main( int argc, char *argv[] )
LAL_CALL
(
LALCreateTwoIFOCoincList
(
&
status
,
&
coincInspiralList
,
inspiralEventList
,
&
accuracyParams
),
&
status
);
if
(
distCut
)
if
(
distCut
)
{
if
(
!
doBCVCVeto
)
{
XLALInspiralDistanceCut
(
&
coincInspiralList
,
&
accuracyParams
);
}
else
{
if
(
vrbflg
)
fprintf
(
stdout
,
"Discarding triggers h1-h2-distance-cut using kappa=%f and epsilon = %f
\n
"
,
accuracyParams
.
ifoAccuracy
[
LAL_IFO_H1
].
kappa
,
accuracyParams
.
ifoAccuracy
[
LAL_IFO_H1
].
epsilon
);
XLALInspiralDistanceCutBCVC
(
&
coincInspiralList
,
&
accuracyParams
);
}
}
XLALInspiralDistanceCut
(
&
coincInspiralList
,
&
accuracyParams
);
}
if
(
multiIfoCoinc
)
{
...
...
@@ -1740,6 +1711,13 @@ cleanexit:
LALFree
(
thisSearchSumm
);
}
/* free the coinc inspirals before the sngl inspirals */
while
(
coincInspiralList
)
{
thisCoinc
=
coincInspiralList
;
coincInspiralList
=
coincInspiralList
->
next
;
XLALFreeCoincInspiral
(
&
thisCoinc
);
}
/* free the snglInspirals */
while
(
inspiralEventList
)
...
...
@@ -1756,14 +1734,6 @@ cleanexit:
LAL_CALL
(
LALFreeSnglInspiral
(
&
status
,
&
thisInspiralTrigger
),
&
status
);
}
while
(
coincInspiralList
)
{
thisCoinc
=
coincInspiralList
;
coincInspiralList
=
coincInspiralList
->
next
;
XLALFreeCoincInspiral
(
&
thisCoinc
);
}
if
(
userTag
)
free
(
userTag
);
if
(
ifoTag
)
free
(
ifoTag
);
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment