flaredetector: properly reset deltaCount
This commit is contained in:
@@ -62,6 +62,8 @@ def getFlareRange(flux, peakIndex):
|
|||||||
if(deltaCount > 3):
|
if(deltaCount > 3):
|
||||||
minInd = i
|
minInd = i
|
||||||
break
|
break
|
||||||
|
else:
|
||||||
|
deltaCount = 0
|
||||||
prevFlux = flux[i]
|
prevFlux = flux[i]
|
||||||
|
|
||||||
if(minInd == -np.inf):
|
if(minInd == -np.inf):
|
||||||
@@ -83,6 +85,8 @@ def getFlareRange(flux, peakIndex):
|
|||||||
if(deltaCount > 3):
|
if(deltaCount > 3):
|
||||||
maxInd = i
|
maxInd = i
|
||||||
break
|
break
|
||||||
|
else:
|
||||||
|
deltaCount = 0
|
||||||
prevFlux = flux[i]
|
prevFlux = flux[i]
|
||||||
|
|
||||||
if(maxInd == np.inf):
|
if(maxInd == np.inf):
|
||||||
|
|||||||
Reference in New Issue
Block a user