コード例 #1
0
ファイル: markers.py プロジェクト: claudioquaglia/PyXRD
 def add_match(self, name, abbreviation, peaks):
     matches = score_minerals(self.marker_peaks, [(name, abbreviation, peaks)])
     if len(matches):
         name, abbreviation, peaks, matches, score = matches[0]
     else:
         matches, score = [], 0.0
     self.matches.append([name, abbreviation, peaks, matches, score])
     sorted(self._matches, key=lambda match: match[-1], reverse=True)
     self.matches_changed.emit()
コード例 #2
0
 def add_match(self, name, abbreviation, peaks):
     matches = score_minerals(self.marker_peaks,
                              [(name, abbreviation, peaks)])
     if len(matches):
         name, abbreviation, peaks, matches, score = matches[0]
     else:
         matches, score = [], 0.
     self.matches.append([name, abbreviation, peaks, matches, score])
     sorted(self._matches, key=lambda match: match[-1], reverse=True)
     self.matches_changed.emit()
コード例 #3
0
 def auto_match(self):
     self._matches = score_minerals(self.marker_peaks, self.minerals)
     self.matches_changed.emit()
コード例 #4
0
ファイル: markers.py プロジェクト: claudioquaglia/PyXRD
 def auto_match(self):
     self._matches = score_minerals(self.marker_peaks, self.minerals)
     self.matches_changed.emit()