当前位置: 首页 > news >正文

地震反演基础知识2(代码演示)

文章目录

  • 数据集代码演示
    • 1. SEG盐真实数据
    • 2. SEG盐速度模型
    • 3. SEG盐模拟地震数据
    • 4. SEG盐模拟速度模型
    • 5. openfwi地震数据
    • 6. openfwi速度模型

数据集代码演示

1. SEG盐真实数据

# 绘制SEG盐层数据的地震图像
def pain_seg_seismic_data(para_seismic_data):'''Plotting seismic data images of SEG salt datasets:param para_seismic_data:   Seismic data (400 x 301) (numpy):param is_colorbar:         Whether to add a color bar (1 means add, 0 is the default, means don't add)'''fig, ax = plt.subplots(figsize=(6.2, 8), dpi=120)im = ax.imshow(para_seismic_data, extent=[0, 300, 400, 0], cmap=plt.cm.seismic, vmin=-0.4, vmax=0.44)ax.set_xlabel('Position (km)', font21)ax.set_ylabel('Time (s)', font21)ax.set_xticks(np.linspace(0, 300, 5))ax.set_yticks(np.linspace(0, 400, 5))ax.set_xticklabels(labels=[0, 0.75, 1.5, 2.25, 3.0], size=21)ax.set_yticklabels(labels=[0.0, 0.50, 1.00, 1.50, 2.00], size=21)plt.rcParams['font.size'] = 14  # Set colorbar font sizedivider = make_axes_locatable(ax)cax = divider.append_axes("top", size="3%", pad=0.32)plt.colorbar(im, ax=ax, cax=cax, orientation='horizontal')plt.subplots_adjust(bottom=0.08, top=0.98, left=0.11, right=0.99)plt.show()

在这里插入图片描述

2. SEG盐速度模型

def pain_seg_velocity_model(para_velocity_model):''':param para_velocity_model: Velocity model (200 x 301) (numpy):param min_velocity:        Upper limit of velocity in the velocity model:param max_velocity:        Lower limit of velocity in the velocity model:return:'''fig, ax = plt.subplots(figsize=(5.8, 4.3), dpi=150)im = ax.imshow(para_velocity_model, extent=[0, 3, 2, 0])ax.set_xlabel('Position (km)', font18)ax.set_ylabel('Depth (km)', font18)ax.tick_params(labelsize=14)plt.rcParams['font.size'] = 14  # Set colorbar font sizedivider = make_axes_locatable(ax)cax = divider.append_axes("top", size="3%", pad=0.32)plt.colorbar(im, ax=ax, cax=cax, orientation='horizontal')plt.subplots_adjust(bottom=0.12, top=0.95, left=0.11, right=0.99)plt.show()

在这里插入图片描述

3. SEG盐模拟地震数据

def pain_seg_seismic_data(para_seismic_data):'''Plotting seismic data images of SEG salt datasets:param para_seismic_data:   Seismic data (400 x 301) (numpy):param is_colorbar:         Whether to add a color bar (1 means add, 0 is the default, means don't add)'''fig, ax = plt.subplots(figsize=(6.2, 8), dpi=120)im = ax.imshow(para_seismic_data, extent=[0, 300, 400, 0], cmap=plt.cm.seismic, vmin=-0.4, vmax=0.44)ax.set_xlabel('Position (km)', font21)ax.set_ylabel('Time (s)', font21)ax.set_xticks(np.linspace(0, 300, 5))ax.set_yticks(np.linspace(0, 400, 5))ax.set_xticklabels(labels=[0, 0.75, 1.5, 2.25, 3.0], size=21)ax.set_yticklabels(labels=[0.0, 0.50, 1.00, 1.50, 2.00], size=21)plt.rcParams['font.size'] = 14  # Set colorbar font sizedivider = make_axes_locatable(ax)cax = divider.append_axes("top", size="3%", pad=0.32)plt.colorbar(im, ax=ax, cax=cax, orientation='horizontal')plt.subplots_adjust(bottom=0.08, top=0.98, left=0.11, right=0.99)plt.show()

在这里插入图片描述

4. SEG盐模拟速度模型

def pain_seg_velocity_model(para_velocity_model):''':param para_velocity_model: Velocity model (200 x 301) (numpy):param min_velocity:        Upper limit of velocity in the velocity model:param max_velocity:        Lower limit of velocity in the velocity model:return:'''fig, ax = plt.subplots(figsize=(5.8, 4.3), dpi=150)im = ax.imshow(para_velocity_model, extent=[0, 3, 2, 0])ax.set_xlabel('Position (km)', font18)ax.set_ylabel('Depth (km)', font18)ax.tick_params(labelsize=14)plt.rcParams['font.size'] = 14  # Set colorbar font sizedivider = make_axes_locatable(ax)cax = divider.append_axes("top", size="3%", pad=0.32)plt.colorbar(im, ax=ax, cax=cax, orientation='horizontal')plt.subplots_adjust(bottom=0.12, top=0.95, left=0.11, right=0.99)plt.show()

在这里插入图片描述

5. openfwi地震数据

def pain_openfwi_seismic_data(para_seismic_data):'''Plotting seismic data images of openfwi dataset:param para_seismic_data:   Seismic data (1000 x 70) (numpy)'''data = cv2.resize(para_seismic_data, dsize=(400, 301), interpolation=cv2.INTER_CUBIC)fig, ax = plt.subplots(figsize=(6.1, 8), dpi=120)im = ax.imshow(data, extent=[0, 0.7, 1.0, 0], cmap=plt.cm.seismic, vmin=-18, vmax=19)ax.set_xlabel('Position (km)', font21)ax.set_ylabel('Time (s)', font21)ax.set_xticks(np.linspace(0, 0.7, 5))ax.set_yticks(np.linspace(0, 1.0, 5))ax.set_xticklabels(labels=[0, 0.17, 0.35, 0.52, 0.7], size=21)ax.set_yticklabels(labels=[0, 0.25, 0.5, 0.75, 1.0], size=21)plt.rcParams['font.size'] = 14  # Set colorbar font sizedivider = make_axes_locatable(ax)cax = divider.append_axes("top", size="3%", pad=0.3)plt.colorbar(im, ax=ax, cax=cax, orientation='horizontal')plt.subplots_adjust(bottom=0.08, top=0.98, left=0.11, right=0.99)plt.show()

在这里插入图片描述

6. openfwi速度模型

def pain_openfwi_velocity_model(para_velocity_model):'''Plotting seismic data images of openfwi dataset:param para_velocity_model: Velocity model (70 x 70) (numpy):param min_velocity:        Upper limit of velocity in the velocity model:param max_velocity:        Lower limit of velocity in the velocity model:param is_colorbar:         Whether to add a color bar (1 means add, 0 is the default, means don't add):return:'''fig, ax = plt.subplots(figsize=(5.8, 6), dpi=150)im = ax.imshow(para_velocity_model, extent=[0, 0.7, 0.7, 0])ax.set_xlabel('Position (km)', font18)ax.set_ylabel('Depth (km)', font18)ax.set_xticks(np.linspace(0, 0.7, 8))ax.set_yticks(np.linspace(0, 0.7, 8))ax.set_xticklabels(labels=[0, 0.1, 0.2, 0.3, 0.4, 0.5, 0.6, 0.7], size=18)ax.set_yticklabels(labels=[0, 0.1, 0.2, 0.3, 0.4, 0.5, 0.6, 0.7], size=18)plt.rcParams['font.size'] = 14  # Set colorbar font sizedivider = make_axes_locatable(ax)cax = divider.append_axes("top", size="3%", pad=0.35)plt.colorbar(im, ax=ax, cax=cax, orientation='horizontal')plt.subplots_adjust(bottom=0.10, top=0.95, left=0.13, right=0.95)plt.show()

在这里插入图片描述

http://www.lryc.cn/news/163995.html

相关文章:

  • C#学习 - 方法的定义、调用、调试
  • 『PyQt5-Qt Designer篇』| 09 Qt Designer中分割线和间隔如何使用?
  • 基于springboot2+mybatis-plus+jsp增删改查
  • [PHP]empty一直返回true
  • [2023.09.11]: Yew的SSR中的Cargo.toml配置
  • HTTPS加密协议详解:HTTPS性能与优化
  • 9月11日,每日信息差
  • RHCSA-VM-Linux基础配置命令
  • Web安全研究(四)
  • 【CS324】Large Language Models(持续更新)
  • 【学习笔记】「2020-2021 集训队作业」Communication Network
  • 文章参考链接
  • SQLI-labs-第七关
  • 腾讯云轻量2核4G5M服务器_CPU内存_流量_带宽_系统盘
  • 从零开始搭建Apache服务器并使用内网穿透技术实现公网访问
  • unordered_map和unordered_set的使用
  • javascript【格式化时间日期】
  • CCC数字钥匙设计【NFC】--什么是AID?
  • 变压器耐压试验电压及电源容量的计算
  • uniapp实现底部弹出菜单选择
  • 14. 线性代数 - 线性方程组
  • C++QT day4
  • Python中的 if __name__ ==‘main‘
  • github 创建自己的分支 并下载代码
  • 算法:贪心---跳一跳
  • 机器学习入门教学——梯度下降、梯度上升
  • BUUCTF Reverse/[羊城杯 2020]login(python程序)
  • indexDB localForage
  • Spring Boot开发时Java对象和Json对象互转
  • C++ 多态