Skip to content

Commit

Permalink
Merge pull request #26 from wearable-motion-capture/summary_paper
Browse files Browse the repository at this point in the history
Summary paper
  • Loading branch information
faweigend authored Feb 5, 2024
2 parents 7c48be6 + e7b4db9 commit 70dbd89
Show file tree
Hide file tree
Showing 8 changed files with 2 additions and 51 deletions.
File renamed without changes.
2 changes: 1 addition & 1 deletion experimental_scripts/watch_phone_to_ros.py
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@
# left ROS publisher
wp2ul = WatchPhoneROS()
ul_thread = threading.Thread(
target=wp2ul.stream_loop,
target=wp2ul.processing_loop,
args=(left_q,)
)
ul_thread.start()
2 changes: 1 addition & 1 deletion setup.cfg
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[metadata]
name = wear_mocap_ape
version = 1.2.0
version = 1.2.2
author = Fabian Weigend
author_email = fweigend@asu.edu
description =
Expand Down
45 changes: 0 additions & 45 deletions src/wear_mocap_ape/estimate/watch_phone_uarm.py
Original file line number Diff line number Diff line change
Expand Up @@ -31,13 +31,6 @@ def __init__(self,
# simple lookup for values of interest
self.__slp = messaging.WATCH_PHONE_IMU_LOOKUP

# in left hand mode, the arm is stretched along the negative X-axis in T pose
# if not left_hand_mode:
# self._larm_vec[0] = -self._larm_vec[0]
# self._uarm_vec[0] = -self._uarm_vec[0]
# self._uarm_orig = self._uarm_orig * np.array([-1, 1, 1]) # invert x
# self._body_measurements = np.r_[self._larm_vec, self._uarm_vec, self._uarm_orig][np.newaxis, :]

def calibrate_orientation_quats(self,
sw_quat: np.array,
sw_fwd: np.array,
Expand Down Expand Up @@ -68,44 +61,6 @@ def parse_row_to_xx(self, row: np.array):
if not type(row) is np.array:
row = np.array(row)

# # get relevant entries from the row
# if len(row.shape) > 1:
# # get relevant entries from the row
# sw_fwd = np.c_[
# row[:, self.__slp["sw_forward_w"]], row[:, self.__slp["sw_forward_x"]],
# row[:, self.__slp["sw_forward_y"]], row[:, self.__slp["sw_forward_z"]]
# ]
# sw_rot = np.c_[
# row[:, self.__slp["sw_rotvec_w"]], row[:, self.__slp["sw_rotvec_x"]],
# row[:, self.__slp["sw_rotvec_y"]], row[:, self.__slp["sw_rotvec_z"]]
# ]
#
# ph_fwd = np.c_[
# row[:, self.__slp["ph_forward_w"]], row[:, self.__slp["ph_forward_x"]],
# row[:, self.__slp["ph_forward_y"]], row[:, self.__slp["ph_forward_z"]]
# ]
#
# ph_rot = np.c_[
# row[:, self.__slp["ph_rotvec_w"]], row[:, self.__slp["ph_rotvec_x"]],
# row[:, self.__slp["ph_rotvec_y"]], row[:, self.__slp["ph_rotvec_z"]]
# ]
#
# sw_sensor_dat = np.c_[
# row[:, self.__slp["sw_dt"]],
# row[:, self.__slp["sw_gyro_x"]], row[:, self.__slp["sw_gyro_y"]], row[:, self.__slp["sw_gyro_z"]],
# row[:, self.__slp["sw_lvel_x"]], row[:, self.__slp["sw_lvel_y"]], row[:, self.__slp["sw_lvel_z"]],
# row[:, self.__slp["sw_lacc_x"]], row[:, self.__slp["sw_lacc_y"]], row[:, self.__slp["sw_lacc_z"]],
# row[:, self.__slp["sw_grav_x"]], row[:, self.__slp["sw_grav_y"]], row[:, self.__slp["sw_grav_z"]]
# ]
# r_pres = row[:, self.__slp["sw_pres"]] - row[:, self.__slp["sw_init_pres"]]
#
# ph_sensor_dat = np.c_[
# row[:, self.__slp["ph_gyro_x"]], row[:, self.__slp["ph_gyro_y"]], row[:, self.__slp["ph_gyro_z"]],
# row[:, self.__slp["ph_lvel_x"]], row[:, self.__slp["ph_lvel_y"]], row[:, self.__slp["ph_lvel_z"]],
# row[:, self.__slp["ph_lacc_x"]], row[:, self.__slp["ph_lacc_y"]], row[:, self.__slp["ph_lacc_z"]],
# row[:, self.__slp["ph_grav_x"]], row[:, self.__slp["ph_grav_y"]], row[:, self.__slp["ph_grav_z"]]
# ]
# else:
sw_fwd = np.array([
row[self.__slp["sw_forward_w"]], row[self.__slp["sw_forward_x"]],
row[self.__slp["sw_forward_y"]], row[self.__slp["sw_forward_z"]]
Expand Down
2 changes: 0 additions & 2 deletions src/wear_mocap_ape/record/watch_phone_uarm_rec.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,11 +9,9 @@ class WatchPhoneUarmRecorder(WatchPhoneUarm):
def __init__(self,
file: Path,
smooth: int = 5,
left_hand_mode=True,
tag: str = "REC WATCH PHONE",
bonemap: BoneMap = None):
super().__init__(smooth=smooth,
left_hand_mode=left_hand_mode,
tag=tag,
bonemap=bonemap)
self.__tag = tag
Expand Down
2 changes: 0 additions & 2 deletions src/wear_mocap_ape/stream/publisher/watch_phone_uarm_ros.py
Original file line number Diff line number Diff line change
Expand Up @@ -12,11 +12,9 @@ def __init__(self,
ros_node_name="/wear_mocap",
ros_rate=20,
smooth: int = 5,
left_hand_mode=True,
tag: str = "PUB WATCH PHONE",
bonemap: BoneMap = None):
super().__init__(smooth=smooth,
left_hand_mode=left_hand_mode,
tag=tag,
bonemap=bonemap)

Expand Down

0 comments on commit 70dbd89

Please sign in to comment.