当前位置: 首页>>代码示例>>Python>>正文


Python AzimuthalIntegrator.wavelength方法代码示例

本文整理汇总了Python中pyFAI.azimuthalIntegrator.AzimuthalIntegrator.wavelength方法的典型用法代码示例。如果您正苦于以下问题:Python AzimuthalIntegrator.wavelength方法的具体用法?Python AzimuthalIntegrator.wavelength怎么用?Python AzimuthalIntegrator.wavelength使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在pyFAI.azimuthalIntegrator.AzimuthalIntegrator的用法示例。


在下文中一共展示了AzimuthalIntegrator.wavelength方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Python代码示例。

示例1: AzimuthalIntegrator

# 需要导入模块: from pyFAI.azimuthalIntegrator import AzimuthalIntegrator [as 别名]
# 或者: from pyFAI.azimuthalIntegrator.AzimuthalIntegrator import wavelength [as 别名]
tilt = 0 #degree
rotation = 0 #degree
pixel_size = 79 #um

#some initialization
dummy_tth = np.linspace(0, 35, 2000)
dummy_int = np.ones(dummy_tth.shape)
geometry = AzimuthalIntegrator()
geometry.setFit2D(directDist=detector_distance,
                  centerX=center_x,
                  centerY=center_y,
                  tilt=tilt,
                  tiltPlanRotation=rotation,
                  pixelX=pixel_size,
                  pixelY=pixel_size)
geometry.wavelength = wavelength/1e10
dummy_img = geometry.calcfrom1d(dummy_tth, dummy_int, shape=image_shape, correctSolidAngle=True)


tth_array = geometry.twoThetaArray(image_shape)
azi_array = geometry.chiArray(image_shape)


cbn_correction = CbnCorrection(tth_array, azi_array,
                               diamond_thickness=2.2,
                               seat_thickness=5.3,
                               small_cbn_seat_radius=0.4,
                               large_cbn_seat_radius=1.95,
                               tilt=0,
                               tilt_rotation=0)
开发者ID:ggarba,项目名称:Dioptas,代码行数:32,代码来源:profiling_cbn_correction.py

示例2: float

# 需要导入模块: from pyFAI.azimuthalIntegrator import AzimuthalIntegrator [as 别名]
# 或者: from pyFAI.azimuthalIntegrator.AzimuthalIntegrator import wavelength [as 别名]
        elif param.startswith("-d="):
            dummy = float(param.split("=", 1)[1])
        elif param.startswith("-dd="):
            delta_dummy = float(param.split("=", 1)[1])
        elif param.startswith("-m="):
            mask = param.split("=", 1)[1]
        elif param.startswith("-h"):
            print (__doc__)
            sys.exit(1)
        elif os.path.isfile(param):
            processFile.append(param)

    if paramFile and processFile:
        integrator.load(paramFile)
        if wavelength is not None:
            integrator.wavelength = wavelength
        print integrator
        if mask is not None:
            mask = 1 - fabio.open(mask).data
        for oneFile in processFile:
            t0 = time.time()
            fabioFile = fabio.open(oneFile)
            if fabioFile.nframes > 1:
                for meth in ["BBox", "cython", "numpy"]:
                    outFile = os.path.splitext(oneFile)[0] + "_" + meth + ".dat"
                    integrator.saxs(
                        data=fabioFile.data.astype("float32"),
                        nbPt=min(fabioFile.data.shape),
                        dummy=dummy,
                        delta_dummy=delta_dummy,
                        mask=mask,
开发者ID:kif,项目名称:pyFAI_debian,代码行数:33,代码来源:saxs_integrate_exp.py


注:本文中的pyFAI.azimuthalIntegrator.AzimuthalIntegrator.wavelength方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。