Permalink
Browse files

Fixed two bugs in gmpe.py and one in mtreader.py

  • Loading branch information...
1 parent 4dc6064 commit bb4a195f098c2df7fdd87c394db1b52d2b91b629 @mhearne-usgs mhearne-usgs committed Jan 28, 2013
Showing with 3 additions and 3 deletions.
  1. +2 −2 strec/gmpe.py
  2. +1 −1 strec/mtreader.py
View
4 strec/gmpe.py
@@ -355,7 +355,7 @@ def selectGMPE(self,lat,lon,depth,magnitude,date=None,forceComposite=False,plung
gmpe,warning = self.getGMPE(trdict,depth)
warning = self.combineWarnings(warning,distwarning,fmwarning)
sresults = StrecResults(lat,lon,depth,magnitude,date,
- gmpe,fmstring,regdict,trdict2,
+ gmpe,fmstring,regdict,trdict,
plungevals,slabvals,eqdict,warning,mtsource)
return sresults
#at this point, seis. category is either 31 or 34
@@ -394,7 +394,7 @@ def selectGMPE(self,lat,lon,depth,magnitude,date=None,forceComposite=False,plung
plungevals,slabvals,eqdict,warning,mtsource)
return sresults
else: #slabflag is 'c'
- gmpe,slabvals,eqdict,warning = self.getAllSubductionZoneInfo(lat,lon,depth,plungevals,slabvals[0],trdict['slabflag'],fmstring,trdict)
+ gmpe,slabvals,eqdict,warning = self.getAllSubductionZoneInfo(lat,lon,depth,plungevals,slabvals,trdict['slabflag'],fmstring,trdict)
warning = self.combineWarnings(warning,distwarning,fmwarning)
sresults = StrecResults(lat,lon,depth,magnitude,date,
gmpe,fmstring,regdict,trdict,
View
2 strec/mtreader.py
@@ -72,7 +72,7 @@ def createDataFile(infile,dbfile,filetype,dtype,hasHeader=False):
conn.commit()
cursor.close()
conn.close()
- appendDataFile(infile,dbfile,filetype,dtype,hasHeader=False)
+ appendDataFile(infile,dbfile,filetype,dtype,hasHeader=hasHeader)
return True
class MTReader(object):

0 comments on commit bb4a195

Please sign in to comment.