示例#1
0
文件: train.py 项目: fkwai/geolearn
from hydroDL.data import dbBasin
from hydroDL.master import basinFull

dataNameLst = ['bsWN5', 'bsDN5', 'brWN5', 'brDN5']

dataName = 'bsWN5'

dm = dbBasin.DataModelFull(dataName)

varX = dm.varF + ['runoff']
varY = usgs.newC
varXC = dm.varG
varYC = None
sd = '1982-01-01'
ed = '2009-12-31'

outName = '{}-B10'.format(dataName)
dictP = basinFull.wrapMaster(outName=outName,
                             dataName=dataName,
                             varX=varX,
                             varY=varY,
                             varXC=varXC,
                             varYC=varYC,
                             sd=sd,
                             ed=ed,
                             nEpoch=100,
                             batchSize=[365, 100])

basinFull.trainModel(outName)
示例#2
0
import argparse
import os
from hydroDL.master import basinFull

if __name__ == '__main__':
    parser = argparse.ArgumentParser()
    parser.add_argument('-M', dest='masterName', type=str)
    args = parser.parse_args()
    basinFull.trainModel(args.masterName)