Commit b0f997e3 authored by brunner's avatar brunner
Browse files

alles guet

parent d6b4742c
...@@ -108,16 +108,17 @@ class ObservationOperator(object): ...@@ -108,16 +108,17 @@ class ObservationOperator(object):
self.lambda_file = os.path.join(self.outputdir, 'lambda.%s.nc' % self.dacycle['time.sample.stamp']) self.lambda_file = os.path.join(self.outputdir, 'lambda.%s.nc' % self.dacycle['time.sample.stamp'])
ofile = Dataset(self.lambda_file, mode='w') ofile = Dataset(self.lambda_file, mode='w')
opar = ofile.createDimension('param', self.nparams) opar = ofile.createDimension('nparam', self.nparams)
omem = ofile.createDimension('member', self.forecast_nmembers)#len(members.nmembers)) omem = ofile.createDimension('nensembles', self.forecast_nmembers)#len(members.nmembers))
l = ofile.createVariable('lambda', np.float32, ('member','param'),fill_value=-999.99) l = ofile.createVariable('lambda', np.float32, ('nensembles','nparam'),fill_value=-999.99)
co2 = np.empty(shape=(self.forecast_nmembers,self.nparams)) co2 = np.empty(shape=(self.forecast_nmembers,self.nparams))
for m in range(0,20): for m in range(0,20):
co2[m,:] = members[m].param_values co2[m,:] = members[m].param_values
l[:] = co2 l[:] = co2
ofile.close() ofile.close()
os.system('cp '+self.lambda_file+' '+dacycle['da.vprm']+'/lambdas.nc')
os.chdir(dacycle['da.obsoperator.home']) os.chdir(dacycle['da.obsoperator.home'])
...@@ -127,7 +128,9 @@ class ObservationOperator(object): ...@@ -127,7 +128,9 @@ class ObservationOperator(object):
else: else:
os.rename(dacycle['dir.da_run']+"/"+absolute_start_time+"_"+str(starth+lag*168)+"_"+str(endh+lag*168), dacycle['dir.da_run']+"/non_opt_"+dacycle['time.start'].strftime('%Y%m%d%H')+"_"+str(starth+lag*168)+"_"+str(endh+lag*168)) os.rename(dacycle['dir.da_run']+"/"+absolute_start_time+"_"+str(starth+lag*168)+"_"+str(endh+lag*168), dacycle['dir.da_run']+"/non_opt_"+dacycle['time.start'].strftime('%Y%m%d%H')+"_"+str(starth+lag*168)+"_"+str(endh+lag*168))
os.system('python run_chain.py '+self.dacycle['run.name']+' '+absolute_start_time_ch+' '+str(starth+lag*168)+' '+str(endh+lag*168)+' -j meteo icbc emissions int2lm post_int2lm octe online_vprm cosmo') os.system('python run_chain.py '+self.dacycle['run.name']+' '+absolute_start_time_ch+' '+str(starth+lag*168)+' '+str(endh+lag*168)+' -j octe online_vprm cosmo -f')
sys.exit()
#os.system('python run_chain.py '+self.dacycle['run.name']+' '+absolute_start_time_ch+' '+str(starth+lag*168)+' '+str(endh+lag*168)+' -j meteo icbc emissions int2lm post_int2lm octe online_vprm cosmo')
logging.info('COSMO done!') logging.info('COSMO done!')
os.chdir(dacycle['dir.da_run']) os.chdir(dacycle['dir.da_run'])
......
...@@ -291,7 +291,7 @@ class StateVector(object): ...@@ -291,7 +291,7 @@ class StateVector(object):
self.ensemble_members[lag].append(newmember) self.ensemble_members[lag].append(newmember)
# Create members 1:nmembers and add to ensemble_members list # Create members 1:nmembers and add to ensemble_members list
for member in range(1, self.nmembers): for member in range(1, self.nmembers+1):
# rands = np.random.uniform(low=-1., high=1., size=self.nparams-1) # rands = np.random.uniform(low=-1., high=1., size=self.nparams-1)
# rands_bg = np.random.uniform(low=-0.05, high=0.05, size=1) # rands_bg = np.random.uniform(low=-0.05, high=0.05, size=1)
# rands = np.random.randn(self.nparams-1) # rands = np.random.randn(self.nparams-1)
......
...@@ -99,10 +99,8 @@ da.obsoperator : cosmo ...@@ -99,10 +99,8 @@ da.obsoperator : cosmo
! be used as observation operator in this experiment. ! be used as observation operator in this experiment.
! !
!da.obsoperator.home : /store/empa/em05/parsenov/cosmo_my_prc_chain
da.obsoperator.home : /store/empa/em05/parsenov/cosmo_processing_chain da.obsoperator.home : /store/empa/em05/parsenov/cosmo_processing_chain
da.bio.input : /store/empa/em05/parsenov/cosmo_input/vprm/processed da.vprm : /store/empa/em05/parsenov/cosmo_input/online_vprm
da.bg.input : /store/empa/em05/parsenov/cosmo_input/icbc/processed
da.obsoperator.rc : ${da.obsoperator.home}/tm5-ctdas-ei-zoom.rc da.obsoperator.rc : ${da.obsoperator.home}/tm5-ctdas-ei-zoom.rc
!forward.savestate.exceptsam : TRUE !forward.savestate.exceptsam : TRUE
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment