test_3dgauss_and_3d_plotting.py 文件源码

python
阅读 23 收藏 0 点赞 0 评论 0

项目:CoherentXrayImaging 作者: susannahammarberg 项目源码 文件源码
def plot_crystal2D():

    plt.figure()
    plt.subplot(221)
    plt.imshow(crystal, cmap='gray')
    plt.title('crystal')
    plt.axis('off')

    plt.subplot(223)
    test=crystal_filter2D*crystal_fourier
    plt.imshow(np.log10(abs(test)), cmap='gray')
    plt.title('log10 |FFT2| of crystal')
    plt.axis('off')

    plt.subplot(222)
    plt.imshow(crystal_skewed, cmap='gray')
    plt.xlabel(' x_s')
    plt.ylabel(' y_s')
    plt.title('crystal in skewed coordinates')
    plt.axis('off')

    plt.subplot(224)
    plt.imshow(np.log10(abs(fft_crystal_skewed)), cmap='gray')
    plt.xlabel(' 1/x_s')
    plt.ylabel(' 1/y_s')
    plt.title('log10|FFT| of crystal in skewed coordinates')
    plt.axis('off')

    # plot filtered 2D retrived crystal2D
    plt.figure
    fig,ax = plt.subplots(1)
    plt.imshow(abs((fft.ifft2(fft.ifftshift(test)))))

#plot_crystal2D()


#plt.figure()
#plt.imshow(projectedCrystal)
#plt.title('Orthoganl projection of 3D crystal into x-y-plane')
#plt.xlabel(' x')
#plt.ylabel(' y')
#savefig('test.jpg')
########################plot 3D crystal in all plane cuts
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号