From 53ad10ca4f3e7b89bcbe9fac56ee10507898a31d Mon Sep 17 00:00:00 2001 From: devicerandom Date: Thu, 19 Feb 2009 11:30:57 +0000 Subject: [PATCH] (pcluster.py) fixed crash when file not recognized --- pcluster.py | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/pcluster.py b/pcluster.py index a70a7b7..08222c6 100644 --- a/pcluster.py +++ b/pcluster.py @@ -143,7 +143,13 @@ class pclusterCommands: c+=1 item.identify(self.drivers) itplot=item.curve.default_plots() - peak_location,peak_size=self.exec_has_peaks(item,min_deviation) + try: + peak_location,peak_size=self.exec_has_peaks(item,min_deviation) + except: + #We have troubles with exec_has_peaks (bad curve, whatever). + #Print info and go to next cycle. + print 'Cannot process ',item.path + continue fit_points, contact_point, pl_value, T, cindex, avg = plot_informations(itplot) print '\n\nCurve',item.path, 'is',c,'of',len(self.current_list),': found '+str(len(peak_location))+' peaks.' -- 2.26.2