MuJoCo中的机器人状态获取

news2025/4/23 8:08:11

UR5e机器人xml文件模型

<mujoco model="ur5e">
  <compiler angle="radian" meshdir="assets" autolimits="true"/>

  <option integrator="implicitfast"/>

  <default>
    <default class="ur5e">
      <material specular="0.5" shininess="0.25"/>
      <joint axis="0 1 0" range="-6.28319 6.28319" armature="0.1"/>
      <general gaintype="fixed" biastype="affine" ctrlrange="-6.2831 6.2831" gainprm="2000" biasprm="0 -2000 -400"
        forcerange="-150 150"/>
      <default class="size3">
        <default class="size3_limited">
          <joint range="-3.1415 3.1415"/>
          <general ctrlrange="-3.1415 3.1415"/>
        </default>
      </default>
      <default class="size1">
        <general gainprm="500" biasprm="0 -500 -100" forcerange="-28 28"/>
      </default>
      <default class="visual">
        <geom type="mesh" contype="0" conaffinity="0" group="2"/>
      </default>
      <default class="collision">
        <geom type="capsule" group="3"/>
        <default class="eef_collision">
          <geom type="cylinder"/>
        </default>
      </default>
      <site size="0.001" rgba="0.5 0.5 0.5 0.3" group="4"/>
    </default>
  </default>

  <asset>
    <material class="ur5e" name="black" rgba="0.033 0.033 0.033 1"/>
    <material class="ur5e" name="jointgray" rgba="0.278 0.278 0.278 1"/>
    <material class="ur5e" name="linkgray" rgba="0.82 0.82 0.82 1"/>
    <material class="ur5e" name="urblue" rgba="0.49 0.678 0.8 1"/>

    <mesh file="base_0.obj"/>
    <mesh file="base_1.obj"/>
    <mesh file="shoulder_0.obj"/>
    <mesh file="shoulder_1.obj"/>
    <mesh file="shoulder_2.obj"/>
    <mesh file="upperarm_0.obj"/>
    <mesh file="upperarm_1.obj"/>
    <mesh file="upperarm_2.obj"/>
    <mesh file="upperarm_3.obj"/>
    <mesh file="forearm_0.obj"/>
    <mesh file="forearm_1.obj"/>
    <mesh file="forearm_2.obj"/>
    <mesh file="forearm_3.obj"/>
    <mesh file="wrist1_0.obj"/>
    <mesh file="wrist1_1.obj"/>
    <mesh file="wrist1_2.obj"/>
    <mesh file="wrist2_0.obj"/>
    <mesh file="wrist2_1.obj"/>
    <mesh file="wrist2_2.obj"/>
    <mesh file="wrist3.obj"/>
  </asset>

  <worldbody>
    <light name="spotlight" mode="targetbodycom" target="wrist_2_link" pos="0 -1 2"/>
    <body name="base" quat="1 0 0 0" childclass="ur5e">
      <inertial mass="4.0" pos="0 0 0" diaginertia="0.00443333156 0.00443333156 0.0072"/>
      <geom mesh="base_0" material="black" class="visual"/>
      <geom mesh="base_1" material="jointgray" class="visual"/>
      <body name="shoulder_link" pos="0 0 0.163">
        <inertial mass="3.7" pos="0 0 0" diaginertia="0.0102675 0.0102675 0.00666"/>
        <joint name="shoulder_pan_joint" class="size3" axis="0 0 1"/>
        <geom mesh="shoulder_0" material="urblue" class="visual"/>
        <geom mesh="shoulder_1" material="black" class="visual"/>
        <geom mesh="shoulder_2" material="jointgray" class="visual"/>
        <geom class="collision" size="0.06 0.06" pos="0 0 -0.04"/>
        <body name="upper_arm_link" pos="0 0.138 0" quat="1 0 1 0">
          <inertial mass="8.393" pos="0 0 0.2125" diaginertia="0.133886 0.133886 0.0151074"/>
          <joint name="shoulder_lift_joint" class="size3"/>
          <geom mesh="upperarm_0" material="linkgray" class="visual"/>
          <geom mesh="upperarm_1" material="black" class="visual"/>
          <geom mesh="upperarm_2" material="jointgray" class="visual"/>
          <geom mesh="upperarm_3" material="urblue" class="visual"/>
          <geom class="collision" pos="0 -0.04 0" quat="1 1 0 0" size="0.06 0.06"/>
          <geom class="collision" size="0.05 0.2" pos="0 0 0.2"/>
          <body name="forearm_link" pos="0 -0.131 0.425">
            <inertial mass="2.275" pos="0 0 0.196" diaginertia="0.0311796 0.0311796 0.004095"/>
            <joint name="elbow_joint" class="size3_limited"/>
            <geom mesh="forearm_0" material="urblue" class="visual"/>
            <geom mesh="forearm_1" material="linkgray" class="visual"/>
            <geom mesh="forearm_2" material="black" class="visual"/>
            <geom mesh="forearm_3" material="jointgray" class="visual"/>
            <geom class="collision" pos="0 0.08 0" quat="1 1 0 0" size="0.055 0.06"/>
            <geom class="collision" size="0.038 0.19" pos="0 0 0.2"/>
            <body name="wrist_1_link" pos="0 0 0.392" quat="1 0 1 0">
              <inertial mass="1.219" pos="0 0.127 0" diaginertia="0.0025599 0.0025599 0.0021942"/>
              <joint name="wrist_1_joint" class="size1"/>
              <geom mesh="wrist1_0" material="black" class="visual"/>
              <geom mesh="wrist1_1" material="urblue" class="visual"/>
              <geom mesh="wrist1_2" material="jointgray" class="visual"/>
              <geom class="collision" pos="0 0.05 0" quat="1 1 0 0" size="0.04 0.07"/>
              <body name="wrist_2_link" pos="0 0.127 0">
                <inertial mass="1.219" pos="0 0 0.1" diaginertia="0.0025599 0.0025599 0.0021942"/>
                <joint name="wrist_2_joint" axis="0 0 1" class="size1"/>
                <geom mesh="wrist2_0" material="black" class="visual"/>
                <geom mesh="wrist2_1" material="urblue" class="visual"/>
                <geom mesh="wrist2_2" material="jointgray" class="visual"/>
                <geom class="collision" size="0.04 0.06" pos="0 0 0.04"/>
                <geom class="collision" pos="0 0.02 0.1" quat="1 1 0 0" size="0.04 0.04"/>
                <body name="wrist_3_link" pos="0 0 0.1">
                  <inertial mass="0.1889" pos="0 0.0771683 0" quat="1 0 0 1"
                    diaginertia="0.000132134 9.90863e-05 9.90863e-05"/>
                  <joint name="wrist_3_joint" class="size1"/>
                  <geom material="linkgray" mesh="wrist3" class="visual"/>
                  <geom class="eef_collision" pos="0 0.08 0" quat="1 1 0 0" size="0.04 0.02"/>
                  <site name="attachment_site" pos="0 0.1 0" quat="-1 1 0 0"/>
                </body>
              </body>
            </body>
          </body>
        </body>
      </body>
    </body>
  </worldbody>

  <sensor>
    <force site="attachment_site" name="force_sensor"/>
    <torque site="attachment_site" name="torque_sensor"/>
  </sensor>

  <actuator>
    <general class="size3" name="shoulder_pan" joint="shoulder_pan_joint"/>
    <general class="size3" name="shoulder_lift" joint="shoulder_lift_joint"/>
    <general class="size3_limited" name="elbow" joint="elbow_joint"/>
    <general class="size1" name="wrist_1" joint="wrist_1_joint"/>
    <general class="size1" name="wrist_2" joint="wrist_2_joint"/>
    <general class="size1" name="wrist_3" joint="wrist_3_joint"/>
  </actuator>

  <keyframe>
    <key name="home" qpos="-1.5708 -1.5708 1.5708 -1.5708 -1.5708 0" ctrl="-1.5708 -1.5708 1.5708 -1.5708 -1.5708 0"/>
  </keyframe>
</mujoco>

接触力

  <sensor>
    <force site="attachment_site" name="force_sensor"/>
    <torque site="attachment_site" name="torque_sensor"/>
  </sensor>
## 获取末端受力和力矩
        force = data.sensor('force_sensor').data
        torque = data.sensor('torque_sensor').data

                        ## 获取传感器的位置和旋转矩阵
        sensor_pos = data.site('attachment_site').xpos
        sensor_mat = data.site('attachment_site').xmat.reshape(3, 3)

        ## 将力转换到世界坐标系
        force_world = sensor_mat.dot(force)

        ## 将力矩转换到世界坐标系
        torque_world = sensor_mat.dot(torque)

        ## 合并力和力矩
        end_force = np.concatenate((force_world, torque_world), axis=0)

        ## 计算feedback_force
        feedback_force = np.sqrt(np.sum(np.square(force_world)))

 <body name="wrist_3_link" pos="0 0 0.1">
                                        <inertial mass="0.1889" pos="0 0.0771683 0" quat="1 0 0 1"
                                            diaginertia="0.000132134 9.90863e-05 9.90863e-05"/>
                                        <joint name="wrist_3_joint" class="size1"/>
                                        <geom material="linkgray" mesh="wrist3" class="visual"/>
                                        <geom class="eef_collision" pos="0 0.08 0" quat="1 1 0 0" size="0.04 0.02"/>
                                        <site name="ee_site" pos="0 0.1 0" quat="-1 1 0 0"/>
                                    </body>
 <actuator>
        <general class="size3" name="shoulder_pan" joint="shoulder_pan_joint"/>
        <general class="size3" name="shoulder_lift" joint="shoulder_lift_joint"/>
        <general class="size3_limited" name="elbow" joint="elbow_joint"/>
        <general class="size1" name="wrist_1" joint="wrist_1_joint"/>
        <general class="size1" name="wrist_2" joint="wrist_2_joint"/>
        <general class="size1" name="wrist_3" joint="wrist_3_joint"/>
    </actuator>
def get_ee_pos(self):
        ee_site_id = mujoco.mj_name2id(self.model, mujoco.mjtObj.mjOBJ_SITE, "ee_site")
        return self.data.site_xpos[ee_site_id].copy()
    
    def get_EE_POS_FROM_QPOS(self, qpos):
        self.data.qpos[:self.nq] = qpos[:self.nq]
        mujoco.mj_forward(self.model, self.data)
        ee_site_id = mujoco.mj_name2id(self.model, mujoco.mjtObj.mjOBJ_SITE, "ee_site")
        return self.data.site_xpos[ee_site_id].copy()
    
    def get_EE_JACOBIAN(self):
        ee_site_id = mujoco.mj_name2id(self.model, mujoco.mjtObj.mjOBJ_SITE, "ee_site")
        jacp = np.zeros((3, self.nv))
        jacr = np.zeros((3, self.nv))
        mujoco.mj_jacSite(self.model, self.data, jacp, jacr, ee_site_id)
        return jacp
    
    def get_state(self):
        return np.concatenate([self.data.qpos[:self.nq], self.data.qvel[:self.nv]])
    
    def set_state(self, x):
        self.data.qpos[:self.nq] = x[:self.nq]
        self.data.qvel[:self.nv] = x[self.nq:]
        mujoco.mj_forward(self.model, self.data)
    
    def step(self, u):
        self.data.ctrl[:self.nu] = np.clip(u, -self.model.actuator_ctrlrange[:, 0], self.model.actuator_ctrlrange[:, 1])
        mujoco.mj_step(self.model, self.data)
        return self.get_state()
def get_ee_position(self):
        return self.data.xpos[self.wrist_3_body_id]
    
    def calculate_jacobian(self):
        jacp = np.zeros((3, self.model.nv))
        jacr = np.zeros((3, self.model.nv))
        mujoco.mj_jacBody(self.model, self.data, jacp, jacr, self.wrist_3_body_id)
        return jacp
# Get target joint positions using inverse kinematics
        J = self.calculate_jacobian()
        J_pinv = np.linalg.pinv(J)

    def get_pose(self):
        p = self.data.site_xpos[self.ee_site_idx].copy()    # pos
        R = self.data.site_xmat[self.ee_site_idx].copy()    # rotation matrix

        return p, R.reshape((3,3))
 <site name="end_effector" type="sphere" size="0.005" pos="0.0 0 0.205" euler="0 0 0" rgba="1 0 0 1.00"/>
 <actuator>
        <!-- Physical limits of the actuator. -->
        <motor name="indy_joint0_actuator" joint="indy_joint1" gear="1 0 0 0 0 0" ctrllimited="false" ctrlrange="-1e6 1e6" forcerange="-1e6 1e6"/>
        <motor name="indy_joint1_actuator" joint="indy_joint2" gear="1 0 0 0 0 0" ctrllimited="false" ctrlrange="-1e6 1e6" forcerange="-1e6 1e6"/>
        <motor name="indy_joint2_actuator" joint="indy_joint3" gear="1 0 0 0 0 0" ctrllimited="false" ctrlrange="-1e6 1e6" forcerange="-1e6 1e6"/>
        <motor name="indy_joint3_actuator" joint="indy_joint4" gear="1 0 0 0 0 0" ctrllimited="false" ctrlrange="-1e6 1e6" forcerange="-1e6 1e6"/>
        <motor name="indy_joint4_actuator" joint="indy_joint5" gear="1 0 0 0 0 0" ctrllimited="false" ctrlrange="-1e6 1e6" forcerange="-1e6 1e6"/>
        <motor name="indy_joint5_actuator" joint="indy_joint6" gear="1 0 0 0 0 0" ctrllimited="false" ctrlrange="-1e6 1e6" forcerange="-1e6 1e6"/>
        
        <position ctrllimited="true" ctrlrange="-0.03 0" joint="jointf1" kp="2000" name="actf1"/>
        <position ctrllimited="true" ctrlrange="0.0 0.03" joint="jointf2" kp="2000" name="actf2"/>
    </actuator>

    <sensor>
        <framepos objtype="site" objname="end_effector"/>
        <force name="force_sensor" site="end_effector"/>
        <torque name="torque_sensor" site="end_effector"/>
    </sensor>

def get_contact_force(mj_model, mj_data, body_name):
    bodyId = mujoco.mj_name2id(mj_model, MJ_BODY_OBJ, body_name)
    force_com = mj_data.cfrc_ext[bodyId, :]
    trn_force = force_com.copy()

    return np.hstack((trn_force[3:], trn_force[:3]))

 def get_ee_force(self,):
        sensor_id = mujoco.mj_name2id(self.model, mujoco.mjtObj.mjOBJ_SENSOR, "force_sensor")

        # Get address and dimension of the sensor
        adr = self.model.sensor_adr[sensor_id]
        dim = self.model.sensor_dim[sensor_id]
        force = np.copy(self.data.sensordata[adr:adr + dim])
        # get torque sensor data
        sensor_id = mujoco.mj_name2id(self.model, mujoco.mjtObj.mjOBJ_SENSOR, "torque_sensor")
        adr = self.model.sensor_adr[sensor_id]
        dim = self.model.sensor_dim[sensor_id]
        torque = np.copy(self.data.sensordata[adr:adr + dim])
        force_torque = np.concatenate([force, torque])
        # update robot state

       
        ft , dft = self.lp_filter_implemented(force_torque)
        return ft, dft
def get_ee_force_raw(self,):
        sensor_id = mujoco.mj_name2id(self.model, mujoco.mjtObj.mjOBJ_SENSOR, "force_sensor")

        # Get address and dimension of the sensor
        adr = self.model.sensor_adr[sensor_id]
        dim = self.model.sensor_dim[sensor_id]
        force = np.copy(self.data.sensordata[adr:adr + dim])
        # get torque sensor data
        sensor_id = mujoco.mj_name2id(self.model, mujoco.mjtObj.mjOBJ_SENSOR, "torque_sensor")
        adr = self.model.sensor_adr[sensor_id]
        dim = self.model.sensor_dim[sensor_id]
        torque = np.copy(self.data.sensordata[adr:adr + dim])
        force_torque = np.concatenate([force, torque])

        # force_sensor_data = self.lp_filter_raw(force_torque.reshape((-1, 6)))[0, :]

        ft_raw , dft_raw = self.lp_filter_implemented_raw(force_torque)

        return ft_raw , dft_raw
def transform_rot(self, fe, desired):
        pe, Re = self.get_pose()
        ps, Rs = desired

        R12 = Rs.T @ Re
        Mat = np.block([[R12, np.zeros((3, 3))], [np.zeros((3, 3)), R12]])

        return Mat.dot(fe)

状态获取

def get_jacobian(self):
        """Get 6x7 geometric jacobian matrix."""
        dtype = self.data.qpos.dtype
        N_full = self.model.nv
        jac = np.zeros((6, N_full), dtype=dtype)
        jac_pos = np.zeros((3 , N_full), dtype=dtype)
        jac_rot = np.zeros((3 , N_full), dtype=dtype)
        mujoco.mj_jacSite(
            self.model, self.data,
            jac_pos, jac_rot, self.ee_site_idx)
        jac[3:] = jac_rot.reshape((3, N_full))
        jac[:3] = jac_pos.reshape((3, N_full))
        # only return first 7 dofs
        return jac[:, :self.N].copy()

    def get_body_jacobian(self):
        Js = self.get_jacobian()

        p, R = self.get_pose()

        transform = np.block([[R.T, np.zeros((3,3))], [np.zeros((3,3)), R.T]])

        Jb = transform @ Js

        return Jb

    def get_body_ee_velocity(self):
        Jb = self.get_body_jacobian()
        dq = self.get_joint_velocity()[:self.N]
        Vb = Jb@dq.reshape((-1,1))

        return Vb
    
    def get_spatial_ee_velocity(self):
        Js = self.get_jacobian()
        dq = self.get_joint_velocity()

        Vs = Js@dq.reshape((-1,1))

        return Vs

    def get_joint_pose(self):
        return self.data.qpos.copy()

    def get_joint_velocity(self):
        return self.data.qvel.copy()

    def get_bias_torque(self):
        """Get the gravity and Coriolis, centrifugal torque """
        return self.data.qfrc_bias[:self.N].copy()
    
    def get_full_inertia(self):
        M = np.zeros((self.model.nv, self.model.nv))
        mujoco.mj_fullM(self.model, M, self.data.qM)

        return M[:self.N, :self.N]

    def get_timestep(self):
        """Timestep of the simulator is timestep of controller."""
        return self.model.opt.timestep

    def get_sim_time(self):
        return self.data.time
def get_FT_value_raw(self):
        Fe, dFe = self.robot_state.get_ee_force_raw()
        return -Fe
    
    def get_eg(self, g, gd):
        p = g[:3,3]
        R = g[:3,:3]

        pd = gd[:3,3]
        Rd = gd[:3,:3]

        ep = R.T @ (p - pd)
        eR = vee_map(Rd.T @ R - R.T @ Rd).reshape((-1,))

        return np.hstack((ep, eR)).reshape((-1,1))
 Jb = self.robot_state.get_body_jacobian()

        # M,C,G = self.robot_state.get_dynamic_matrices()
        qfrc_bias = self.robot_state.get_bias_torque()
        M = self.robot_state.get_full_inertia()
def get_bias_torque(self):
        """Get the gravity and Coriolis, centrifugal torque """
        return self.data.qfrc_bias[:self.N].copy()
qfrc_bias = self.robot_state.get_bias_torque()
tau_cmd = Jb.T @ tau_tilde + qfrc_bias.reshape((-1,1))

本文来自互联网用户投稿,该文观点仅代表作者本人,不代表本站立场。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如若转载,请注明出处:http://www.coloradmin.cn/o/2340628.html

如若内容造成侵权/违法违规/事实不符,请联系多彩编程网进行投诉反馈,一经查实,立即删除!

相关文章

测试第四课---------性能测试工具

作者前言 &#x1f382; ✨✨✨✨✨✨&#x1f367;&#x1f367;&#x1f367;&#x1f367;&#x1f367;&#x1f367;&#x1f367;&#x1f382; ​&#x1f382; 作者介绍&#xff1a; &#x1f382;&#x1f382; &#x1f382; &#x1f389;&#x1f389;&#x1f389…

【C++】新手入门指南(下)

文章目录 前言 一、引用 1.引用的概念和定义 2.引用的特性 3.引用的使用 4.const引用 5.指针和引用的关系 二、内联函数 三、nullptr 总结 前言 这篇续上篇的内容新手入门指南&#xff08;上&#xff09;&#xff0c;继续带大家学习新知识。如果你感兴趣欢迎订购本专栏。 一、…

前后端分离项目在未部署条件下如何跨设备通信

其实我此前也不知道这个问题怎么解决&#xff0c;也没有想过—因为做的项目大部分都是前后端分离的&#xff0c;前端直接用后端的部署好的环境就行了。最近也是有点心高气傲开始独立开发&#xff0c;一个人又写前端又写后端也是蛮累的&#xff0c;即使有强有力的cursor也很累很…

基于Python的多光谱遥感数据处理与分类技术实践—以农作物分类与NDVI评估为例

多光谱遥感数据包含可见光至红外波段的光谱信息&#xff0c;Python凭借其丰富的科学计算库&#xff08;如rasterio、scikit-learn、GDAL&#xff09;&#xff0c;已成为处理此类数据的核心工具。本文以Landsat-8数据为例&#xff0c;演示‌辐射校正→特征提取→监督分类→精度评…

vscode python 代码无法函数跳转的问题

TL; DR; python.languageServer 配置成了 None 导致 vscode python 代码无法函数跳转 详细信息 mac 环境下 vscode 正常 command 鼠标左键 可以跳转到定义或者使用位置&#xff0c;但是我的为何不知道失效了 我一开始以为是热键冲突&#xff0c;结果发现 mac 好像没办法定…

Unity 脚本使用(二)——UnityEngine.AI——NavMesh

描述 Singleton class 用于访问被烘培好的 NavMesh. 使用NavMesh类可以执行空间查询&#xff08;spatial queries&#xff09;&#xff0c;例如路径查找和可步行性测试。此类还允许您设置特定区域类型的寻路成本&#xff0c;并调整寻路和避免的全局行为。 静态属性&#xff0…

从项目真实场景中理解二分算法的细节(附图解和模板)

遇到一个真实场景里使用二分算法的问题&#xff0c;本以为可以放心交给小师弟去做&#xff0c;结果出现了各种问题&#xff0c;在此梳理下二分算法的核心思想和使用细节。 文章目录 1.场景描述2.场景分析3.二分算法的精髓3.1 核心模板3.2 二分过程图解3.3 各种区间写法3.3.1 闭…

Jetson Orin NX 16G 配置GO1强化学习运行环境

这一次收到了Jrtson Orin NX, 可以进行部署了。上一次在nano上的失败经验 Jetson nano配置Docker和torch运行环境_jetson docker-CSDN博客 本次的目的是配置cuda-torch-python38环境离机运行策略。 Jetson Orin NX SUPER 1. 烧录镜像 参考链接在ubuntu系统中安装sdk manag…

深度学习3.5 图像分类数据集

%matplotlib inline import torch import torchvision from torch.utils import data from torchvision import transforms from d2l import torch as d2l代码执行流程图 #mermaid-svg-WWhBmQvijswiICpI {font-family:"trebuchet ms",verdana,arial,sans-serif;font-…

js原型链prototype解释

function Person(){} var personnew Person() console.log(啊啊,Person instanceof Function);//true console.log(,Person.__proto__Function.prototype);//true console.log(,Person.prototype.__proto__ Object.prototype);//true console.log(,Function.prototype.__prot…

【知识】性能优化和内存优化的主要方向

转载请注明出处&#xff1a;小锋学长生活大爆炸[xfxuezhagn.cn] 如果本文帮助到了你&#xff0c;欢迎[点赞、收藏、关注]哦~ 前言 现在有很多论文&#xff0c;乍一看很高级&#xff0c;实际上一搜全是现有技术的堆砌&#xff0c;但是这种裁缝式的论文依然能发表在很好的会议和期…

VS Code + GitHub:高效开发工作流指南

目录 一、安装 & 基本配置 1.下载 VS Code 2.安装推荐插件(打开侧边栏 Extensions) 3.设置中文界面(可选) 二、使用 VS Code 操作 Git/GitHub 1.基本 Git 操作(不输命令行!) 2.连接 GitHub(第一次使用) 三、克隆远程仓库到 VS Code 方法一(推荐): 方…

软件测试之接口测试常见面试

一、什么是(软件)接口测试? 接口测试&#xff1a;是测试系统组件间接口的一种测试方法 接口测试的重点&#xff1a;检查数据的交换&#xff0c;数据传递的正确性&#xff0c;以及接口间的逻辑依赖关系 接口测试的意义&#xff1a;在较早期开展&#xff0c;在软件开发的同时…

11、Refs:直接操控元素——React 19 DOM操作秘籍

一、元素操控的魔法本质 "Refs是巫师与麻瓜世界的连接通道&#xff0c;让开发者能像操控魔杖般精准控制DOM元素&#xff01;"魔杖工坊的奥利凡德先生轻抚着魔杖&#xff0c;React/Vue的refs能量在杖尖跃动。 ——以神秘事务司的量子纠缠理论为基&#xff0c;揭示DOM…

uniapp-商城-33-shop 布局搜索页面以及u-search

shop页面上有一个搜索&#xff0c;可以进行商品搜索&#xff0c;这里我们先做一个页面布局&#xff0c;后面再来进行数据i联动。 1、shop页面的搜索 2、搜索的页面代码 <navigator class"searchView" url"/pagesub/pageshop/search/search"> …

【dataframe显示不全问题】打开一个行列超多的excel转成df之后行列显示不全

出现问题如下图&#xff1a; 解决方案&#xff5e; display.width解决列显示不全 pd.set_option(display.max_columns,1000) pd.set_option(display.width, 1000) pd.set_option(display.max_colwidth,1000) pd.set_option(display.max_rows,1000)

Windows下Golang与Nuxt项目宝塔部署指南

在Windows下将Golang后端和Nuxt前端项目打包&#xff0c;并使用宝塔面板部署的步骤如下 一、Golang后端打包 交叉编译为Linux可执行文件 在Windows PowerShell中执行&#xff1a; powershell复制下载 $env:GOOS "linux" $env:GOARCH "amd64" go build…

真实趋势策略思路

该交易策略通过一系列技术指标的计算与逻辑判断&#xff0c;旨在捕捉市场趋势的反转与延续点&#xff0c;以实现盈利。其主要交易逻辑思路可以概括如下&#xff1a; 1. 趋势与动量分析 策略首先利用动量函数计算收盘价的短期&#xff08;3周期&#xff09;变化&#xff0c;通过…

江奇霖惊喜亮相泡泡岛音乐节,新歌首唱+合作舞台燃动现场

2025年4月20日&#xff0c;江奇霖受邀参加2025泡泡岛音乐与艺术节东南站。现场献唱三首歌曲&#xff0c;超5万名观众现场一同感受音乐的魅力。 在泡泡岛SPECIAL SET特别企划舞台中&#xff0c;江奇霖带来新歌的首唱&#xff0c;温暖的旋律如低语倾诉&#xff0c;观众们也纷纷喊…

【HarmonyOS】ArKUI框架

目录 概述 声明式开发范式 基于ArKUI的项目 • 1&#xff0e;创建资源文件 • 2&#xff0e;引用资源 • 3&#xff0e;引用系统资源&#xff1a; • 系统资源有哪些 • 4. 在配置和资源中引用资源 声明式语法 UI描述规范 UI组件概述 组件化 组件渲染控制语法 修改…