Skip to content

Commit

Permalink
Fixed bugs in classify.py when classifying redshift.
Browse files Browse the repository at this point in the history
  • Loading branch information
daniel-muthukrishna committed Jun 1, 2018
1 parent 6975c80 commit 117dd61
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions dash/classify.py
Original file line number Diff line number Diff line change
Expand Up @@ -94,7 +94,7 @@ def list_best_matches(self, n=5, saveFilename='DASH_matches.txt'):
for i in range(20):
host, name, age = classification_split(bestTypes[specNum][i])
if not self.knownZ:
redshifts.append(self.calc_redshift(inputImages[i], name, age)[0], inputMinMaxIndexes[i])
redshifts.append(self.calc_redshift(inputImages[i], name, age, inputMinMaxIndexes[i])[0])
prob = softmaxes[specNum][i]
bestMatchList.append((host, name, age, prob))
bestMatchList = np.array(bestMatchList)
Expand Down Expand Up @@ -162,7 +162,6 @@ def calc_redshift(self, inputFlux, snName, snAge, inputMinMaxIndex):
templateFluxes = []
templateMinMaxIndexes = []
for i in range(numOfSubTemplates):
templateNames = []
templateFluxes.append(snInfos[i][1])
templateMinMaxIndexes.append((snInfos[i][2], snInfos[i][3]))

Expand Down

0 comments on commit 117dd61

Please sign in to comment.