Example #1
0
st = time.clock()
run_id = 0
for kwd in kwds:
    plottrees = readtrees('pnt01.tre.save')

    for x in xrange(reps):
        #bootstrap the plot records
        tls = resampleplots(plottrees)
        writetrees(tls)
        
        #cl = numpy.array((1,),dtype='a100')
        cl = '--keywordfile=%s' % (kwd,)

        #initialize the run
        i = fvs.fvssetcmdline(cl)
        
        #get the size of data arrays
        ## fvsDimSizes(ntrees,ncycles,nplots,maxtrees,maxspecies,maxplots,maxcycles)
        dim_sizes = fvs.fvsdimsizes()
        
        #get a list of species codes for lookup
        ## fvsSpeciesCode(fvs_code,fia_code,plant_code,indx,nchfvs,nchfia,nchplant,rtnCode)
        spp_codes = numpy.array(map(fvs.fvsspeciescode
                ,range(1,dim_sizes[4]+1)))[:,0]

        cycle_year = year_zero

        #get trees
#        tn = fvs.contrl.itrn
#        trees.resize(trees.shape[0]+tn)
Example #2
0
st = time.clock()
run_id = 0
for kwd in kwds:
    plottrees = readtrees('pnt01.tre.save')

    for x in xrange(reps):
        #bootstrap the plot records
        tls = resampleplots(plottrees)
        writetrees(tls)

        #cl = numpy.array((1,),dtype='a100')
        cl = '--keywordfile=%s' % (kwd, )

        #initialize the run
        i = fvs.fvssetcmdline(cl)

        #get the size of data arrays
        ## fvsDimSizes(ntrees,ncycles,nplots,maxtrees,maxspecies,maxplots,maxcycles)
        dim_sizes = fvs.fvsdimsizes()

        #get a list of species codes for lookup
        ## fvsSpeciesCode(fvs_code,fia_code,plant_code,indx,nchfvs,nchfia,nchplant,rtnCode)
        spp_codes = numpy.array(
            map(fvs.fvsspeciescode, range(1, dim_sizes[4] + 1)))[:, 0]

        cycle_year = year_zero

        #get trees
        #        tn = fvs.contrl.itrn
        #        trees.resize(trees.shape[0]+tn)