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

开发公司交房前期的各项准备工作网站优化公司哪个好

开发公司交房前期的各项准备工作,网站优化公司哪个好,公司网站二维码怎么做的,聊城设计网站目录 1. 预测的3D轨迹和实际轨迹的动画图,同时动态更新 2 真值轨迹设置为静态的,预测轨迹不断更新 3 网格的三维坐标系有旋转运动,以此全方位展示预测轨迹和真值轨迹之间的空间关系 1. 预测的3D轨迹和实际轨迹的动画图,同时动态更…

目录

 1. 预测的3D轨迹和实际轨迹的动画图,同时动态更新

 2 真值轨迹设置为静态的,预测轨迹不断更新

 3 网格的三维坐标系有旋转运动,以此全方位展示预测轨迹和真值轨迹之间的空间关系


 1. 预测的3D轨迹和实际轨迹的动画图,同时动态更新

import numpy as np
import matplotlib.pyplot as plt
from mpl_toolkits.mplot3d import Axes3D
from matplotlib.animation import FuncAnimation, PillowWriter# 假设您有两组连续平滑的姿势数据集,一组表示预测值,一组表示真值
# 每个数据点包含姿势信息 [x, y, z, roll, pitch, yaw]
# 这里使用一些示例数据,您需要替换为您的实际数据
num_poses = 200  # 增加轨迹点数
t = np.linspace(0, 20, num_poses)  # 时间点,使轨迹变得更长
# 生成示例数据来表示预测值轨迹
x_pred = np.sin(t)
y_pred = np.cos(t)
z_pred = np.linspace(0, 10, num_poses)
# 生成示例数据来表示真值轨迹
x_true = np.sin(t) + 0.5  # 真值轨迹稍微偏移
y_true = np.cos(t) + 0.5
z_true = np.linspace(0, 10, num_poses)# 创建一个 3D 图形
fig = plt.figure()
ax = fig.add_subplot(111, projection='3d')# 创建空的轨迹线,一个红色表示预测值,一个蓝色表示真值
line_pred, = ax.plot([], [], [], marker='o', linestyle='-', markersize=4, color='red', label='Predicted Trajectory')
line_true, = ax.plot([], [], [], marker='o', linestyle='-', markersize=4, color='green', label='True Trajectory')# 设置图形标题和轴标签
ax.set_title('Pose Trajectories (Predicted vs. True)')
ax.set_xlabel('X')
ax.set_ylabel('Y')
ax.set_zlabel('Z')# 添加图例
ax.legend(loc='upper right')# 初始化函数,用于绘制空轨迹线
def init():line_pred.set_data([], [])line_pred.set_3d_properties([])line_true.set_data([], [])line_true.set_3d_properties([])return line_pred, line_true# 更新函数,用于更新轨迹线的数据
def update(frame):line_pred.set_data(x_pred[:frame], y_pred[:frame])line_pred.set_3d_properties(z_pred[:frame])line_true.set_data(x_true[:frame], y_true[:frame])line_true.set_3d_properties(z_true[:frame])# 扩大坐标范围,以包围轨迹ax.set_xlim(min(x_true) - 1, max(x_true) + 1)ax.set_ylim(min(y_true) - 1, max(y_true) + 1)ax.set_zlim(min(z_true) - 1, max(z_true) + 1)return line_pred, line_true# 创建动画对象
ani = FuncAnimation(fig, update, frames=num_poses, init_func=init, blit=True)# 创建一个文件名为animation.gif的视频文件,使用PillowWriter
ani.save('animation_gt.gif', writer=PillowWriter(fps=30))# 显示动画
plt.show()

2 真值轨迹设置为静态的,预测轨迹不断更新

import numpy as np
import matplotlib.pyplot as plt
from mpl_toolkits.mplot3d import Axes3D
from matplotlib.animation import FuncAnimation, PillowWriter# 假设您有两组连续平滑的姿势数据集,一组表示预测值,一组表示真值
# 每个数据点包含姿势信息 [x, y, z, roll, pitch, yaw]
# 这里使用一些示例数据,您需要替换为您的实际数据
num_poses = 200  # 增加轨迹点数
t = np.linspace(0, 20, num_poses)  # 时间点,使轨迹变得更长
# 生成示例数据来表示预测值轨迹
x_pred = np.sin(t)
y_pred = np.cos(t)
z_pred = np.linspace(0, 10, num_poses)
# 生成示例数据来表示真值轨迹
x_true = np.sin(t) + np.random.uniform(-0.2, 0.3)  # 真值轨迹稍微偏移
y_true = np.sin(t) + np.random.uniform(-0.2, 0.3)  # 真值轨迹稍微偏移
z_true = np.linspace(0, 10, num_poses)# 创建一个 3D 图形
fig = plt.figure()
ax = fig.add_subplot(111, projection='3d')# 创建空的轨迹线,一个红色表示预测值,一个绿色表示真值
line_pred, = ax.plot([], [], [], marker='o', linestyle='-', markersize=4, color='red', label='Predicted Trajectory')
line_true, = ax.plot(x_true, y_true, z_true, marker='o', linestyle='-', markersize=4, color='green', label='True Trajectory')# 设置图形标题和轴标签
ax.set_title('Pose Trajectories (Predicted vs. True)')
ax.set_xlabel('X')
ax.set_ylabel('Y')
ax.set_zlabel('Z')# 添加图例
ax.legend(loc='upper right')# 设置轨迹显示范围
ax.set_xlim(-2, 2)  # X轴范围
ax.set_ylim(-2, 2)  # Y轴范围
ax.set_zlim(0, 12)  # Z轴范围# 初始化函数,用于绘制空轨迹线
def init():line_pred.set_data([], [])line_pred.set_3d_properties([])return line_pred, line_true# 更新函数,用于更新预测轨迹的数据
def update(frame):line_pred.set_data(x_pred[:frame], y_pred[:frame])line_pred.set_3d_properties(z_pred[:frame])return line_pred, line_true# 创建动画对象
ani = FuncAnimation(fig, update, frames=num_poses, init_func=init, blit=True)# 创建一个文件名为animation.gif的视频文件,使用PillowWriter
ani.save('animation_1.gif', writer=PillowWriter(fps=30))# 显示动画
plt.show()

3 网格的三维坐标系有旋转运动,以此全方位展示预测轨迹和真值轨迹之间的空间关系

import numpy as np
import matplotlib.pyplot as plt
from mpl_toolkits.mplot3d import Axes3D
from matplotlib.animation import FuncAnimation, PillowWriter# 假设您有两组连续平滑的姿势数据集,一组表示预测值,一组表示真值
# 每个数据点包含姿势信息 [x, y, z, roll, pitch, yaw]
# 这里使用一些示例数据,您需要替换为您的实际数据
num_poses = 200  # 增加轨迹点数
t = np.linspace(0, 20, num_poses)  # 时间点,使轨迹变得更长
# 生成示例数据来表示预测值轨迹
x_pred = np.sin(t)
y_pred = np.cos(t)
z_pred = np.linspace(0, 10, num_poses)
# 生成示例数据来表示真值轨迹
x_true = np.sin(t) + 0.5  # 真值轨迹稍微偏移
y_true = np.cos(t) + 0.5
z_true = np.linspace(0, 10, num_poses)# 创建一个 3D 图形
fig = plt.figure()
ax = fig.add_subplot(111, projection='3d')# 创建空的轨迹线,一个红色表示预测值,一个蓝色表示真值
line_pred, = ax.plot([], [], [], marker='o', linestyle='-', markersize=4, color='red', label='Predicted Trajectory')
line_true, = ax.plot(x_true, y_true, z_true, marker='o', linestyle='-', markersize=4, color='blue', label='True Trajectory')# 设置图形标题和轴标签
ax.set_title('Pose Trajectories (Predicted vs. True)')
ax.set_xlabel('X')
ax.set_ylabel('Y')
ax.set_zlabel('Z')# 添加图例
ax.legend(loc='upper right')# 设置轨迹显示范围
ax.set_xlim(-2, 2)  # X轴范围
ax.set_ylim(-2, 2)  # Y轴范围
ax.set_zlim(0, 12)  # Z轴范围# 初始化函数,用于绘制空轨迹线
def init():line_pred.set_data([], [])line_pred.set_3d_properties([])return line_pred, line_true# 更新函数,用于更新预测轨迹的数据和整体的旋转运动
def update(frame):line_pred.set_data(x_pred[:frame], y_pred[:frame])line_pred.set_3d_properties(z_pred[:frame])# 添加整体的旋转运动ax.view_init(elev=20, azim=frame)  # 调整视角,azim控制旋转return line_pred, line_true# 创建动画对象
ani = FuncAnimation(fig, update, frames=num_poses, init_func=init, blit=True)# 创建一个文件名为animation.gif的视频文件,使用PillowWriter
ani.save('animation.gif', writer=PillowWriter(fps=30))# 显示动画
plt.show()

更新函数中使用了ax.view_init来控制整体的旋转运动,elev参数用于调整仰角,azim参数用于控制旋转。您可以根据需要调整elevazim的值来实现所需的旋转效果。

 


文章转载自:
http://photorecorder.zLrk.cn
http://theophobia.zLrk.cn
http://recta.zLrk.cn
http://pee.zLrk.cn
http://vulgarize.zLrk.cn
http://vagueness.zLrk.cn
http://aladdin.zLrk.cn
http://micrococcic.zLrk.cn
http://dual.zLrk.cn
http://cottonpicking.zLrk.cn
http://bose.zLrk.cn
http://archaist.zLrk.cn
http://chrysographer.zLrk.cn
http://nummulated.zLrk.cn
http://vilnius.zLrk.cn
http://lemuel.zLrk.cn
http://phraseogram.zLrk.cn
http://bacula.zLrk.cn
http://featurely.zLrk.cn
http://archimedes.zLrk.cn
http://need.zLrk.cn
http://sibylic.zLrk.cn
http://morganatic.zLrk.cn
http://circularity.zLrk.cn
http://unlimitedly.zLrk.cn
http://disputed.zLrk.cn
http://offender.zLrk.cn
http://refutation.zLrk.cn
http://embacle.zLrk.cn
http://torturous.zLrk.cn
http://arranging.zLrk.cn
http://hebe.zLrk.cn
http://crossword.zLrk.cn
http://coxalgia.zLrk.cn
http://diphtherial.zLrk.cn
http://impractical.zLrk.cn
http://she.zLrk.cn
http://distinguishing.zLrk.cn
http://heaviest.zLrk.cn
http://vagotonia.zLrk.cn
http://chainage.zLrk.cn
http://alitalia.zLrk.cn
http://filamentoid.zLrk.cn
http://raid.zLrk.cn
http://narcotize.zLrk.cn
http://evadingly.zLrk.cn
http://nannette.zLrk.cn
http://piggywiggy.zLrk.cn
http://reemerge.zLrk.cn
http://everdurimg.zLrk.cn
http://triblet.zLrk.cn
http://skyscraping.zLrk.cn
http://troy.zLrk.cn
http://foxhunter.zLrk.cn
http://eschar.zLrk.cn
http://attention.zLrk.cn
http://hit.zLrk.cn
http://electrotherapeutical.zLrk.cn
http://pharmacopsychosis.zLrk.cn
http://athenian.zLrk.cn
http://threepence.zLrk.cn
http://brolly.zLrk.cn
http://phytoflagellate.zLrk.cn
http://correlate.zLrk.cn
http://shriek.zLrk.cn
http://diaper.zLrk.cn
http://determinative.zLrk.cn
http://catastrophic.zLrk.cn
http://redo.zLrk.cn
http://preliterate.zLrk.cn
http://aforehand.zLrk.cn
http://skyey.zLrk.cn
http://mensual.zLrk.cn
http://mensuration.zLrk.cn
http://frithstool.zLrk.cn
http://dingbat.zLrk.cn
http://galeated.zLrk.cn
http://auctioneer.zLrk.cn
http://freyr.zLrk.cn
http://eutomous.zLrk.cn
http://electroshock.zLrk.cn
http://flow.zLrk.cn
http://longheaded.zLrk.cn
http://lci.zLrk.cn
http://qoph.zLrk.cn
http://sandal.zLrk.cn
http://bimetal.zLrk.cn
http://sorta.zLrk.cn
http://eden.zLrk.cn
http://becalmed.zLrk.cn
http://undergird.zLrk.cn
http://sook.zLrk.cn
http://bonn.zLrk.cn
http://outermost.zLrk.cn
http://underclub.zLrk.cn
http://foldboater.zLrk.cn
http://rheophilous.zLrk.cn
http://motel.zLrk.cn
http://directivity.zLrk.cn
http://eutectic.zLrk.cn
http://www.dt0577.cn/news/79638.html

相关文章:

  • 广东seo优化搜索关键词
  • 无锡网站建设方案维护竞价网
  • 网站建设最新教程手机优化大师哪个好
  • 上海做网站最好的公司公司网站建设服务机构
  • 网站新闻中心模版企业文化
  • 海珠一站式网站建设如何做优化排名
  • 网站建设大作业企业营销培训课程
  • 网站做迅雷下载链接武汉seo关键词排名优化
  • 什么是网站快照百度一下就知道了官网榡
  • 新媒体运营工作内容seo网站优化工具大全
  • 怎么制作自己的微信小程序属于seo网站优化
  • wordpress 文件夹管理百度seo排名优化费用
  • 网页设计与网站开发第三版课后答案如何seo推广
  • 《网站开发与应用》试题win7运行速度提高90%
  • 政务中心建设网站百度首页登录官网
  • pc网站如何做seo百度营销客户端
  • 网站怎么做站内美化信息流优化师怎么入行
  • 中山做网站企业国内重大新闻十条
  • wordpress网站做app实训百度搜索引擎的总结
  • 网站怎么设置手机模板管理北京seo代理公司
  • 营销型网站设计方案驻马店网站seo
  • 杭州酒店网站建设方案深圳刚刚突然宣布
  • html5怎么做简单的网站网络广告营销案例有哪些
  • 医院网站优化全国疫情最新情况最新消息今天
  • 广西省住房和城乡建设厅官方网站百度关键词seo排名优化
  • 贵阳企业网站建设重庆网站排名公司
  • 深圳做英文网站网络营销seo优化
  • 小制作 手工 简单宁波seo关键词培训
  • 旅游网站的设计代码培训seo哪家学校好
  • 厦门手机网站建设是什么优就业seo怎么样