def __init__(self, fname='<STR_LIT>',<EOL>dir_=None, x_step=<NUM_LIT:0.5> / <NUM_LIT:8>, z_step=<NUM_LIT:0.5> / <NUM_LIT:8>,<EOL>psf_pytables=None):
if psf_pytables is not None:<EOL><INDENT>self.psflab_psf_raw = psf_pytables[:]<EOL>for name in ['<STR_LIT>', '<STR_LIT>', '<STR_LIT>', '<STR_LIT>']:<EOL><INDENT>setattr(self, name, psf_pytables.get_attr(name))<EOL><DEDENT><DEDENT>else:<EOL><INDENT>self.fname = fname<EOL>if dir_ is None:<EOL><INDENT>dir_ = pkg_resources.resource_filename('<STR_LIT>', '<STR_LIT>')<EOL><DEDENT>self.dir_ = dir_<EOL>self.x_step, self.z_step = x_step, z_step<EOL>self.psflab_psf_raw = load_PSFLab_file('<STR_LIT:/>'.join([dir_, fname]))<EOL><DEDENT>xi, zi, hdata, zm = convert_PSFLab_xz(self.psflab_psf_raw,<EOL>x_step=x_step, z_step=z_step,<EOL>normalize=True)<EOL>self._fun_um = SI.RectBivariateSpline(xi, zi, hdata.T, kx=<NUM_LIT:1>, ky=<NUM_LIT:1>)<EOL>self.xi, self.zi, self.hdata, self.zm = xi, zi, hdata, zm<EOL>self.x_step, self.z_step = xi[<NUM_LIT:1>] - xi[<NUM_LIT:0>], zi[<NUM_LIT:1>] - zi[<NUM_LIT:0>]<EOL>self.kind = '<STR_LIT>'<EOL>
Create a PSF object for interpolation from numeric data.

        `dir_+fname`: should be a valid path

        If `dir_` is None use the "system" folder where the PSF shipped with
        pybromo are placed.