Skip to content

AttributeError: 'module' object has no attribute 'wavepy' #11

@michaelrushford

Description

@michaelrushford

I wanted to follow the phase screen wiki demo but got this error from "LongRangeImaging = wavepy.wavepy()" when running the code below..

import numpy as np
import wavepy.utils as wpu
import wavepy

Instantiate a default WavePy object

LongRangeImaging = wavepy.wavepy()

Set Turbulence strength parameter

LongRangeImaging.SetCn2Rytov(0.1)

Generation of phase screen

phz_hi = self.PhaseScreen()
#FFT-based phase screens

phz_lo = self.SubHarmonicComp(5)
#sub harmonics

phz = phz_lo + phz_hi
#Component addition

#Iteration and multi-screen approach
for iter in range(0, numberOfIterations,1):
for idxscr in range(0,self.NumScr,1):
phz_hi[:,:,idxscr] = self.PhaseScreen()
#FFT-based phase screens

    phz_lo[:,:,idxscr] = self.SubHarmonicComp(5)
    #sub harmonics

    phz[:,:,idxscr] = phz_lo[:,:,idxscr] + phz_hi[:,:,idxscr]
    #subharmonic compensated phase screens

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions