Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/PaulDanielML/MuJoCo_RL_UR5
/ functions
Functions
93 in github.com/PaulDanielML/MuJoCo_RL_UR5
⨍
Functions
93
◇
Types & classes
11
↓ 8 callers
Method
move_ee
Moves the robot arm so that the gripper center ends up at the requested XYZ-position, with a vertical gripper position. Args
gym_grasper/controller/MujocoController.py:446
↓ 8 callers
Method
reset
(self)
Offline RL/train.py:235
↓ 7 callers
Method
move_group_to_joint_target
Moves the specified joint group to a joint target. Args: group: String specifying the group to move. target:
gym_grasper/controller/MujocoController.py:269
↓ 7 callers
Method
step
Lets the agent execute the action. Args: action: The action to be performed. Returns: observation:
gym_grasper/envs/GraspingEnv.py:62
↓ 6 callers
Method
stay
Holds the current position by actuating the joints towards their current target position. Args: duration: Time in ms to
gym_grasper/controller/MujocoController.py:621
↓ 6 callers
Method
update
(self, val, n=1)
Offline RL/train.py:241
↓ 5 callers
Method
close
(self)
gym_grasper/envs/GraspingEnv.py:479
↓ 4 callers
Function
MULTIDISCRETE_RESNET
(number_actions_dim_2)
Modules.py:308
↓ 4 callers
Method
__init__
(self, h, w, outputs)
Modules.py:59
↓ 4 callers
Method
push
(self, *args)
Modules.py:36
↓ 4 callers
Method
transform_observation
Takes an observation dictionary, transforms it into a normalized tensor of shape (1,4,height,width). The returned tensor will already
Grasping_Agent_multidiscrete.py:301
↓ 3 callers
Method
close_gripper
Closes the gripper while keeping the arm in a steady position.
gym_grasper/controller/MujocoController.py:423
↓ 3 callers
Function
conv3x3
3x3 convolution with padding
Modules.py:145
↓ 3 callers
Method
get_observation
Uses the controllers get_image_data method to return an top-down image (as a np-array). Args: show: If True, displays th
gym_grasper/envs/GraspingEnv.py:390
↓ 2 callers
Method
add_marker
Adds a circular red marker at the coordinates, dislaying the coordinates as a label. Args: coordinates: List of XYZ-coor
gym_grasper/controller/MujocoController.py:808
↓ 2 callers
Function
binary_accuracy
Checks weather each predictions lies within a specified threshold of the ground truth
Offline RL/train.py:198
↓ 2 callers
Method
create_camera_data
Initializes all camera parameters that only need to be calculated once.
gym_grasper/controller/MujocoController.py:742
↓ 2 callers
Method
create_group
Allows the user to create custom objects for controlling groups of joints. The method show_model_info can be used to get lists of joi
gym_grasper/controller/MujocoController.py:53
↓ 2 callers
Method
epsilon_greedy
Returns an action according to the epsilon-greedy policy. Args: state: An observation / state that will be forwarded thr
Grasping_Agent_multidiscrete.py:232
↓ 2 callers
Method
get_image_data
Returns the RGB and depth images of the provided camera. Args: show: If True displays the images for five seconds or unt
gym_grasper/controller/MujocoController.py:708
↓ 2 callers
Method
grasp
Attempts a grasp at the current location and prints some feedback on weather it was successful
gym_grasper/controller/MujocoController.py:436
↓ 2 callers
Method
ik
Method for solving simple inverse kinematic problems. This was developed for top down graspig, therefore the solution will be one whe
gym_grasper/controller/MujocoController.py:467
↓ 2 callers
Method
learn
Example implementaion of a training method, using standard DQN-learning. Samples batches from the replay buffer, feeds them through t
Grasping_Agent_multidiscrete.py:388
↓ 2 callers
Method
open_gripper
Opens the gripper while keeping the arm in a steady position.
gym_grasper/controller/MujocoController.py:408
↓ 2 callers
Method
pixel_2_world
Converts pixel coordinates into world coordinates. Args: pixel_x: X-coordinate in pixel space. pixel_y: Y-co
gym_grasper/controller/MujocoController.py:783
↓ 2 callers
Method
rotate_wrist_3_joint_to_value
(self, degrees)
gym_grasper/envs/GraspingEnv.py:193
↓ 2 callers
Method
sample
(self, batch_size)
Modules.py:46
↓ 2 callers
Method
set_group_joint_target
(self, group, target)
gym_grasper/controller/MujocoController.py:395
↓ 2 callers
Method
transform_action
(self, action)
Grasping_Agent_multidiscrete.py:381
↓ 2 callers
Method
update_tensorboard
Method for keeping track of tensorboard metrics. Args: reward: Reward to be added to the list of last 1000 rewards.
Grasping_Agent_multidiscrete.py:448
↓ 1 callers
Function
count_parameters
(model)
Modules.py:314
↓ 1 callers
Method
create_joint_angle_plot
Saves the recorded joint values as a .png-file. The values for each joint of the group are put in a seperate subplot. Args:
gym_grasper/controller/MujocoController.py:654
↓ 1 callers
Method
create_lists
Creates some basic lists and fill them with initial values. This function is called in the class costructor. The following lists/dict
gym_grasper/controller/MujocoController.py:136
↓ 1 callers
Method
depth_2_meters
Converts the depth array delivered by MuJoCo (values between 0 and 1) into actual m values. Args: depth: The depth array
gym_grasper/controller/MujocoController.py:729
↓ 1 callers
Function
eval_on_test_set
()
Offline RL/train.py:167
↓ 1 callers
Method
fill_plot_list
Creates a two dimensional list of joint angles for plotting. Args: group: The group involved in the movement.
gym_grasper/controller/MujocoController.py:639
↓ 1 callers
Method
get_mean_std
Reads and returns the mean and standard deviation values created by 'normalize.py'.
Grasping_Agent_multidiscrete.py:370
↓ 1 callers
Function
main
()
Grasping_Agent_multidiscrete.py:515
↓ 1 callers
Function
main
()
Offline RL/train.py:90
↓ 1 callers
Function
main
()
Offline RL/generate_data.py:14
↓ 1 callers
Method
move_and_grasp
( self, coordinates, rotation, render=False, record_grasps=False, markers=False, plot=False )
gym_grasper/envs/GraspingEnv.py:205
↓ 1 callers
Method
print_info
(self)
gym_grasper/envs/GraspingEnv.py:483
↓ 1 callers
Method
show_model_info
Displays relevant model info for the user, namely bodies, joints, actuators, as well as their IDs and ranges. Also gives info on whic
gym_grasper/controller/MujocoController.py:79
↓ 1 callers
Function
test
(arg1, arg2, arg3)
decorators.py:113
↓ 1 callers
Method
toss_it_from_the_ellbow
Test method for trying out tossing of grasped objects.
gym_grasper/controller/MujocoController.py:604
↓ 1 callers
Method
transform_observation
(self, observation, normalize=True, jitter_and_noise=True)
Offline RL/grasping_dataset.py:42
Function
POLICY_RESNET
()
Modules.py:304
Function
RESNET
()
Modules.py:300
Function
Transform_Image
(means, stds)
Modules.py:16
Method
__getitem__
(self, idx)
Offline RL/grasping_dataset.py:29
Method
__init__
(self, size, simple=False)
Modules.py:29
Method
__init__
( self, inplanes, planes, stride=1, downsample=None, groups=1,
Modules.py:95
Method
__init__
(self)
Modules.py:160
Method
__init__
(self, output_activation="Sigmoid")
Modules.py:197
Method
__init__
(self, output_activation="Sigmoid", act_dim_2=6)
Modules.py:244
Method
__init__
Args: height: Observation height (in pixels). width: Observation width (in pixels). mem_size: Number of t
Grasping_Agent_multidiscrete.py:52
Method
__init__
(self, model=None, simulation=None, viewer=None)
gym_grasper/controller/MujocoController.py:29
Method
__init__
( self, file="/UR5+gripper/UR5gripper_2_finger_many_objects.xml", image_width=200,
gym_grasper/envs/GraspingEnv.py:28
Method
__init__
(self, file)
Offline RL/grasping_dataset.py:13
Method
__init__
(self, name, fmt=":f")
Offline RL/train.py:230
Method
__len__
(self)
Modules.py:54
Method
__len__
(self)
Offline RL/grasping_dataset.py:26
Method
__repr__
(self)
gym_grasper/envs/GraspingEnv.py:59
Method
__str__
(self)
Offline RL/train.py:248
Method
_set_action_space
(self)
gym_grasper/envs/GraspingEnv.py:158
Method
actuate_joint_group
(self, group, motor_values)
gym_grasper/controller/MujocoController.py:256
Method
backward_gradient_hook
Hook for displaying the indices of non-zero gradients. Useful for making sure only the loss of pixels corresponding to selected actio
Modules.py:289
Method
conv2d_size_out
(size, kernel_size=5, stride=3)
Modules.py:70
Function
debug
Prints the function signature and return value
decorators.py:22
Function
decorate
(func)
decorators.py:71
Function
dict2list
(func)
decorators.py:91
Method
display_current_values
Debug method, simply displays some relevant data at the time of the call.
gym_grasper/controller/MujocoController.py:540
Method
forward
(self, x)
Modules.py:79
Method
forward
(self, x)
Modules.py:126
Method
forward
(self, x, verbose=0)
Modules.py:170
Method
forward
(self, x, verbose=0)
Modules.py:209
Method
forward
(self, x, verbose=0)
Modules.py:256
Method
get
(self, index)
Modules.py:51
Function
get_mean_std
()
Modules.py:20
Method
greedy
Always returns the greedy action. For demonstrating learned behaviour. Args: state: An observation / state that will be
Grasping_Agent_multidiscrete.py:284
Method
ik_2
TODO: Implement orientation.
gym_grasper/controller/MujocoController.py:519
Method
last_steps
(self)
gym_grasper/controller/MujocoController.py:828
Method
reset_model
Method to perform additional reset steps and return an observation. Gets called in the parent classes reset method.
gym_grasper/envs/GraspingEnv.py:409
Method
set_grasp_position
Legacy method, not used in the current setup. May be used to directly set the joint values to a desired position.
gym_grasper/envs/GraspingEnv.py:169
Function
size_parameters
Use this setter for changing .
decorators.py:56
Function
timer
Prints the runtime of the decorated function.
decorators.py:7
Method
transform_height
(self, height_action, depth_height)
gym_grasper/envs/GraspingEnv.py:199
Function
typeassert
(*ty_args, **ty_kwargs)
decorators.py:70
Method
world_2_pixel
Takes a XYZ world position and transforms it into pixel coordinates. Mainly implemented for testing the correctness of the camera mat
gym_grasper/controller/MujocoController.py:761
Function
wrapper
(*args, **kwargs)
decorators.py:78
Function
wrapper_debug
(*args, **kwargs)
decorators.py:26
Function
wrapper_dict2list
(*args, **kwargs)
decorators.py:93
Function
wrapper_timer
(*args, **kwargs)
decorators.py:11