Beispiel #1
0
#Create the DM object.
from util.dm import dmOverview, dmInfo
import numpy
if ndm > 1:
    dmHeight = numpy.arange(ndm) * (hList[-1] / (ndm - 1.))
else:
    dmHeight = [0]
dmInfoList = []
for i in range(ndm):
    dmInfoList.append(
        dmInfo('dm%dpath' % i, [x.idstr for x in sourceList],
               dmHeight[i],
               nAct,
               minarea=0.1,
               actuatorsFrom="recon",
               pokeSpacing=(None if wfs_nsubx < 20 else 10),
               maxActDist=1.5,
               decayFactor=0.,
               reconLam=lgsLam,
               closedLoop=0))
for i in range(nsci):
    #Add the virtual DM projector
    dmInfoList.append(
        dmInfo('vdmsci%d' % (i + 1), ["sci%d" % (i + 1)],
               0,
               nAct,
               minarea=0.1,
               actuatorsFrom=["dm%dpath" % x for x in range(ndm)],
               maxActDist=1.5,
               decayFactor=0.,
               reconLam=lgsLam,
Beispiel #2
0
atmosGeom = geom(atmosDict, sourceList, ntel, npup, telDiam, r0, l0)

#Create the DM object.
from util.dm import dmOverview, dmInfo
import numpy
if ndm > 1:
    dmHeight = numpy.arange(ndm) * (hList[-1] / (ndm - 1.))
else:
    dmHeight = [0]
dmInfoList = []
for i in range(ndm):
    dmInfoList.append(
        dmInfo('dm%dpath' % i, [x.idstr for x in sourceList],
               dmHeight[i],
               nAct,
               minarea=0.1,
               actuatorsFrom="recon",
               pokeSpacing=(None if wfs_nsubx < 20 else 10),
               maxActDist=1.5,
               decayFactor=0.95))
dmInfoList.append(
    dmInfo('vdm', ["sci1"],
           0,
           nAct,
           minarea=0.1,
           actuatorsFrom=["dm%dpath" % x for x in range(ndm)],
           maxActDist=1.5,
           decayFactor=0.95,
           reconLam=lgsLam))
dmOverview = dmOverview(dmInfoList, atmosGeom)

#reconstructor
Beispiel #3
0
sourceList=[]
#the wfs
sourceList.append(wfsOverview.getWfsByID("1"))

#and psf
for i in range(nsci):
 sourceList.append(sciOverview.getSciByID("sci%d"%(i+1)))


atmosGeom=geom(atmosDict,sourceList,ntel,npup,telDiam,r0,l0)
this.physProp.atmosGeom=geom(atmosDict,sourceList,this.physProp.ntel,this.physProp.npup,this.physProp.telDiam,r0,l0,ignoreZenithWarning=1)
this.infScrn.atmosGeom=this.physProp.atmosGeom



#Create the DM object.
nAct=wfs_nsubx+1
from util.dm import dmOverview,dmInfo
dmInfoList=[dmInfo('dm',[x.idstr for x in sourceList],0.,nAct,minarea=0.1,actuatorsFrom="recon",pokeSpacing=(None if wfs_nsubx<20 else 10),maxActDist=1.5,decayFactor=0.95)]
dmOverview=dmOverview(dmInfoList,atmosGeom)

rcond=0.05#condtioning value for SVD
recontype="pinv"#reconstruction type
pokeval=1.#strength of poke
gainFactor=0.5#Loop gain
computeControl=1#To compute the control matrix after poking
reconmxFilename="rmx.fits"#control matrix name (will be created)
pmxFilename="pmx.fits"#interation matrix name (will be created)

Beispiel #4
0
dirList = [0.]  #direction (degrees) of the layers
for i in range(nlayer):
    atmosDict["L%d" % i] = layer(hList[i], dirList[i], vList[i], strList[i],
                                 10 + i)
sourceList = []
#the wfs
sourceList.append(wfsOverview.getWfsByID("a"))
#and psf
sourceList.append(sciOverview.getSciByID("m"))
l0 = 10.  #outer scale
r0 = 0.137  #fried's parameter
atmosGeom = geom(atmosDict, sourceList, ntel, npup, telDiam, r0, l0)

#Create the DM object.
from util.dm import dmOverview, dmInfo
dmInfoList=[dmInfo('dm',['a','m'],0.,nAct,minarea=0.1,actuatorsFrom="ngs",\
                   pokeSpacing=(None if wfs_nsubx<20 else 10),maxActDist=1.5,interpType="hex")]
dmObj = dmOverview(dmInfoList, atmosGeom)

seed = 1

#reconstructor
this.tomoRecon = new()
r = this.tomoRecon
r.rcond = 0.05  #condtioning value for SVD
r.recontype = "pinv"  #reconstruction type
r.pokeval = 1.  #strength of poke
r.gainFactor = 0.5  #Loop gain
r.computeControl = 1  #To compute the control matrix after poking
r.reconmxFilename = "rmx.fits"  #control matrix name (will be created)
r.pmxFilename = "pmx.fits"  #interation matrix name (will be created)
Beispiel #5
0
vList=[10.]*nlayer#velocity of the layers
dirList=range(0,nlayer*10,10)#direction (degrees) of the layers
for i in range(nlayer):
 atmosDict["L%d"%i]=layer(hList[i],dirList[i],vList[i],strList[i],10+i)

l0=10. #outer scale
r0=0.137 #fried's parameter
atmosGeom=geom(atmosDict,sourceList,ntel,npup,telDiam,r0,l0)

print atmosGeom.getWFSOrder("darc")
#Create the DM object.
from util.dm import dmOverview,dmInfo
import numpy
dmHeight=0
dmInfoList=[]
dmInfoList.append(dmInfo('dm0path',[x.idstr for x in sourceList],dmHeight,15,minarea=0.5,closedLoop=0,reconLam=ngsLam,actuatorsFrom="darc",maxActDist=0.6,interpType="pspline"))
dmInfoList.append(dmInfo('ttpath',[x.idstr for x in sourceList],dmHeight,3,minarea=0.1,actuatorsFrom="darc",closedLoop=1,zonalDM=0,reconLam=ngsLam))

dmOverview=dmOverview(dmInfoList,atmosGeom)

# #reconstructor
# this.tomoRecon=new()
# r=this.tomoRecon
# r.rcond=0.05#condtioning value for SVD
# r.recontype="pinv"#reconstruction type
# r.pokeval=1.#strength of poke
# r.gainFactor=0.5#Loop gain
# r.computeControl=1#To compute the control matrix after poking
# r.reconmxFilename="rmx.fits"#control matrix name (will be created)
# r.pmxFilename="pmx.fits"#interation matrix name (will be created)