hexrd.wppf.LeBailCalibration module
- class hexrd.wppf.LeBailCalibration.LeBailCalibrator(instrument, img_dict, extent=(0.0, 90.0, 0.0, 360.0), pixel_size=(0.1, 1.0), params=None, phases=None, azimuthal_step=5.0, bkgmethod={'chebyshev': 3}, peakshape='pvtch', intensity_init=None, apply_solid_angle_correction=False, apply_lp_correction=False, polarization=None)[source]
Bases:
object
- >> @AUTHOR: Saransh Singh, Lawrence Livermore National Lab,
>> @DATE: 08/24/2021 SS 1.0 original
>> @DETAILS: new lebail class which is specifically designed for instrument calibration using the LeBail method. in this partcular implementation, instead of using the iterative method for computing the peak intensities, we will use them as parameters in the optimization problem. the inputs include the instrument, the imageseries, material, peakshapes etc.
- >> @PARAMETERS instrument the instrument class in hexrd
img_dict dictionary of images with same keys as detectors in the instrument class
- Refine()[source]
>> @AUTHOR: Saransh Singh, Lawrence Livermore National Lab, saransh1@llnl.gov >> @DATE: 05/19/2020 SS 1.0 original >> @DETAILS: this routine performs the least squares refinement for all variables
which are allowed to be varied.
- property azimuthal_chunks
- property azimuthal_step
- property bkgdegree
- calcrwp(params)[source]
this is one of the main functions which differs fundamentally to the regular Lebail class. this function computes the residual as a colletion of residuals at different eta, omega values. for the most traditional HED case, we will have only a single value of omega. However, there will be support for the more complicated HEDM case in the future.
- computespectrum(instr_updated, lp_updated)[source]
this function calls the computespectrum function in the lebaillight class for all the azimuthal positions and accumulates the error vector from each of those lineouts. this is more or less a book keeping function rather
- property extent
- property img_dict
- property init_time
- initialize_Icalc()[source]
@DATE 01/22/2021 SS modified the function so Icalc can be initialized with a dictionary of structure factors
- property instrument
- property lpcorrection
- property params
- property peakshape
- property phases
- property pixel_size
- property polarization
- property refine_background
- property refine_instrument
- property refine_tilt
- property refine_translation
- property sacorrection
- property shkl
- property tth_list
- property tth_max
- property tth_min
- update_param_vals(params)[source]
@date 03/12/2021 SS 1.0 original take values in parameters and set the corresponding class values with the same name
- update_shkl(params)[source]
if certain shkls are refined, then update them using the params arg. else use values from the parameter class
- property wavelength
- class hexrd.wppf.LeBailCalibration.LeBaillight(name, lineout, Icalc, tth, hkls, dsp, shkl, lebail_param_list, params, peakshape, bkgmethod)[source]
Bases:
object
just a lightweight LeBail class which does only the simple computation of diffraction spectrum given the parameters and intensity values
- CalcIobs()[source]
>> @AUTHOR: Saransh Singh, Lawrence Livermore National Lab, saransh1@llnl.gov >> @DATE: 06/08/2020 SS 1.0 original >> @DETAILS: this is one of the main functions to partition the expt intensities
to overlapping peaks in the calculated pattern
- property Icalc
- property background
- property bkgdegree
- property calc_Iobs_fcn
- property computespectrum_fcn
- property dsp
- property hkls
- property lineout
- property mask
- property params
- property spectrum_expt
- property spectrum_sim
- property tth
- property tth_list
- property tth_step
- property weights