Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Make DM map and command functions to outside of ServiceProxy. #260

Merged
merged 1 commit into from
Oct 25, 2024

Conversation

ehpor
Copy link
Collaborator

@ehpor ehpor commented Oct 25, 2024

This allows us to operate on DM commands without spinning up an entire simulator.

@ehpor ehpor added the enhancement New feature or request label Oct 25, 2024
@ehpor ehpor requested a review from ivalaginja October 25, 2024 00:50
@ehpor ehpor self-assigned this Oct 25, 2024
command_length = np.sum(device_actuator_mask)

# If we're given a DM map, convert it to a command.
if dm_shape.shape != (command_length,):
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is the comma here on purpose?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, it's a comparison with a tuple. No new code, it was just moved from inside to outside the class.

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

oh right

Copy link
Collaborator

@ivalaginja ivalaginja left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I had hacked my way through this for THD2, thanks for actually doing this properly.

This allows us to operate on DM commands without spinning up an entire simulator.
@ehpor ehpor force-pushed the feature/dm_map_command_functions branch from ca71309 to 5d21fa7 Compare October 25, 2024 20:16
@ehpor ehpor enabled auto-merge October 25, 2024 20:16
@ehpor ehpor merged commit bc6c921 into develop Oct 25, 2024
6 checks passed
@ehpor ehpor deleted the feature/dm_map_command_functions branch October 25, 2024 20:23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants