Skip to content

PCA and Plotting Code #4

Open
aileenliao03 wants to merge 3 commits into
mit-biomimetics:mainfrom
aileenliao03:main
Open

PCA and Plotting Code #4
aileenliao03 wants to merge 3 commits into
mit-biomimetics:mainfrom
aileenliao03:main

Conversation

@aileenliao03
Copy link
Copy Markdown

Includes data logging to npz file (play_ORC.py), pca calculations (skeletonpca.py), and plotting (plot.py).

@aileenliao03 aileenliao03 requested review from se-hwan and sheim March 6, 2024 14:41
@aileenliao03 aileenliao03 self-assigned this Mar 7, 2024
Copy link
Copy Markdown

@se-hwan se-hwan left a comment

Choose a reason for hiding this comment

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

Generally, seems like the code is functional, but I'm a little confused by some of the hard coded numbers - try to avoid writing these directly if you can.

Also, if you could delete any parts of scripts, or entire scripts you're not using, that'd be useful for clarity. And generally, try not to push files that aren't code, it makes it difficult to keep track of things.

When we meet, let's try to clean up the workspace and repo a little bit, and discuss results!

Comment thread gym/scripts/pca.py
env.cfg.init_state.reset_mode = "reset_to_range"

return env
args = get_args()
Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Why do we have to start the environment? This is just an analysis script from excel data right?

Comment thread gym/scripts/pcasteve.py
args = get_args()
env = setup(args)

#import data
Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Same thing here, probably can delete this so the script runs faster

Comment thread gym/scripts/play_ORC.py
interface.update(env)
#print(env.num_envs)
#print(env.torques.size())
log['dof_pos_obs'] += (env.dof_pos_obs.tolist())
Copy link
Copy Markdown

Choose a reason for hiding this comment

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

We should probably also log the absolute dof_pos

Comment thread gym/scripts/ssa.py
phase_env2 = np.empty((0,n))
phase_env3 = np.empty((0,n))
phase_env4 = np.empty((0,n))
phases = [phase_env1, phase_env2, phase_env3, phase_env4]
Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Why do we have separate variables for 4 phase environments?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants