MCPcopy Create free account

hub / github.com/NVlabs/CTG / functions

Functions1,831 in github.com/NVlabs/CTG

↓ 123 callersMethodto_numpy
(self)
tbsim/policies/common.py:61
↓ 116 callersMethodtype
(self)
tbsim/dynamics/base.py:40
↓ 109 callersFunctionbatch_utils
()
tbsim/utils/batch_utils.py:19
↓ 81 callersMethodclone
(self)
tbsim/configs/config.py:189
↓ 55 callersFunctionpad_sequence
Pad a nested dictionary or list or tuple of sequence tensors in the time dimension (dimension 1). Args: seq (dict or list or tuple):
tbsim/utils/tensor_utils.py:900
↓ 36 callersMethodcompute_losses
(pred_batch, data_batch)
tbsim/algos/algos.py:366
↓ 36 callersMethodparse_batch
(data_batch)
tbsim/utils/batch_utils.py:72
↓ 35 callersMethodto_dict
(self)
tbsim/configs/config.py:91
↓ 31 callersMethodupdate
(self, *args, **kwargs)
tbsim/configs/config.py:117
↓ 29 callersMethodextend
(self, param_configs: List[ParamConfig])
tbsim/utils/experiment_utils.py:89
↓ 28 callersMethodsample
Draw data samples (x') given a batch of condition inputs (x_c) and the VAE prior. Args: condition_inputs (dict, torch.Te
tbsim/models/vaes.py:341
↓ 26 callersMethodget_current_states
Get the dynamic states of the current timestep Note: Support both agent-centric and scene-centric (extra dimension for th
tbsim/utils/batch_utils.py:46
↓ 25 callersMethod__init__
(self, in_channels, out_channels, bilinear=True)
tbsim/models/base_models.py:259
↓ 24 callersMethod__init__
- query : query for GPT API.
tbsim/utils/guidance_loss.py:1544
↓ 24 callersMethodeval
Set the policy to evaluation mode
tbsim/policies/base.py:14
↓ 23 callersFunctionrecursive_dict_list_tuple_apply
Recursively apply functions to a nested dictionary or list or tuple, given a dictionary of {data_type: function_to_apply}. Args:
tbsim/utils/tensor_utils.py:12
↓ 22 callersFunctionget_checkpoint
Get checkpoint and config path given either a ngc job ID or a local dir. If a @ngc_job_id is specified, the function will first look for a d
tbsim/utils/experiment_utils.py:497
↓ 22 callersFunctionget_experiment_config_from_file
(file_path, locked=False)
tbsim/utils/config_utils.py:27
↓ 21 callersFunctiontransform_points_tensor
Transform a set of 2D/3D points using the given transformation matrix. Assumes row major ordering of the input points. The transform function
tbsim/utils/geometry_utils.py:98
↓ 20 callersFunctionextract
(a, t, x_shape)
tbsim/models/diffuser_helpers.py:446
↓ 20 callersFunctionget_registered_experiment_config
(registered_name)
tbsim/configs/registry.py:451
↓ 19 callersMethod__init__
(self, layer, N)
tbsim/models/Transformer.py:119
↓ 19 callersMethodcopy
(self)
tbsim/configs/config.py:104
↓ 19 callersMethodget_modality_shapes
(self, exp_cfg: ExperimentConfig)
tbsim/evaluation/policy_composers.py:57
↓ 19 callersMethodtic
(self)
tbsim/utils/timer.py:20
↓ 19 callersMethodtoc
(self, average=True)
tbsim/utils/timer.py:25
↓ 17 callersFunctionselect_agent_ind
(x, i)
tbsim/utils/trajdata_utils.py:547
↓ 16 callersMethodfrom_dict
(cls, d)
tbsim/policies/common.py:49
↓ 16 callersMethodto_dict
(self)
tbsim/policies/common.py:89
↓ 15 callersMethod__init__
(self)
tbsim/configs/algo_config.py:133
↓ 15 callersMethodget_drivable_region_map
(rasterized_map)
tbsim/utils/batch_utils.py:100
↓ 15 callersMethodget_metrics
(self)
tbsim/envs/base.py:28
↓ 15 callersFunctionmap_ndarray
Apply function @func to np.ndarray objects in a nested dictionary or list or tuple. Args: x (dict or list or tuple): a possibly
tbsim/utils/tensor_utils.py:80
↓ 14 callersFunctionclones
Produce N identical layers.
tbsim/models/Transformer.py:15
↓ 14 callersMethodclose
(self)
tbsim/utils/diffuser_utils/progress.py:148
↓ 14 callersMethodeval
(self)
tbsim/policies/wrappers.py:152
↓ 14 callersMethodget_action
(self, obs, **kwargs)
tbsim/policies/wrappers.py:155
↓ 14 callersMethodget_last_available_index
Args: avails (torch.Tensor): target availabilities [B, (A), T] Returns: last_indices (torch.Tensor): index o
tbsim/utils/batch_utils.py:31
↓ 13 callersMethod__init__
(self, algo_config, modality_shapes)
tbsim/algos/algos.py:259
↓ 13 callersMethod__init__
(self, beta)
tbsim/models/diffuser_helpers.py:911
↓ 13 callersMethodupdate
(self, coords, raster_from_world, lane_map, agent_ids, episode_index, threshold=0.1,weight=1)
tbsim/envs/env_metrics.py:1031
↓ 13 callersMethodwrap_controller
(cls, model, **kwargs)
tbsim/policies/wrappers.py:162
↓ 12 callersMethodforward
(self, data_batch: Dict[str, torch.Tensor])
tbsim/models/rasterized_models.py:147
↓ 12 callersMethodperturb
Given the observation object, add Gaussian noise to positions and yaws Args: obs(Dict[torch.tensor]): observation dict R
tbsim/utils/metrics.py:612
↓ 11 callersMethod__init__
(self, sim_dt=0.1, stat_dt=0.5)
tbsim/envs/env_metrics.py:1439
↓ 11 callersMethodlock
(self, should_lock=True)
tbsim/configs/config.py:166
↓ 11 callersMethodstep
(self, action, num_steps_to_take, render)
tbsim/envs/base.py:20
↓ 11 callersFunctiontrajectory_loss
Aggregated per-step loss between gt and predicted trajectories Args: predictions (torch.Tensor): predicted trajectory [B, (A), T, D]
tbsim/utils/loss_utils.py:260
↓ 11 callersMethodupdate
(self,key)
tbsim/utils/metrics.py:597
↓ 10 callersMethod_get_planner
(self)
tbsim/evaluation/policy_composers.py:315
↓ 10 callersMethodcompute_metrics
(pred_batch, data_batch)
tbsim/algos/algos.py:339
↓ 9 callersMethodconvert_action_to_state_and_action
Apply dynamics on input action trajectory to get state+action trajectory Note: Support both agent-centric and scene-centr
tbsim/models/scenediffuser.py:1037
↓ 9 callersFunctionget_agt_color
(agt_idx)
tbsim/utils/scene_edit_utils.py:855
↓ 9 callersFunctionparse_trajdata_batch
(batch: dict, overwrite_nan=True)
tbsim/utils/trajdata_utils.py:507
↓ 9 callersMethodtransform
(self, trans_mats, rot_rads)
tbsim/policies/common.py:99
↓ 8 callersMethodadd_step
(self, state_info: dict, all_scene_index: np.ndarray)
tbsim/envs/env_metrics.py:1455
↓ 8 callersMethodcompute_guidance_loss
Evaluates all guidance losses and total and individual values. - x_loss: (B, N, T, 6) the trajectory to use to compute losses and 6 i
tbsim/utils/guidance_loss.py:2143
↓ 8 callersMethoddescale_traj
scale back the trajectory from standard normal distribution to original scale Note: Support both agent-centric and scene-
tbsim/models/scenediffuser.py:1088
↓ 8 callersFunctionget_agents_future
Queries the sim scene for the future state traj (in global frame) of all agents. - sim_scene : to query - fut_sec : how far in the future
tbsim/utils/scene_edit_utils.py:178
↓ 8 callersMethodoutput_shape
Function to compute output shape from inputs to this module. Args: input_shape (iterable of int): shape of input. Does no
tbsim/models/base_models.py:80
↓ 8 callersMethodprepare_scene_agent_hist
Input: - pos : (B, M, (Q), T, 2) - yaw : (B, M, (Q), T, 1) - speed : (B, M, (Q), T) - extent: (B, M, (Q), 3)
tbsim/models/scenediffuser.py:445
↓ 8 callersMethodtimed
(self, key)
tbsim/utils/timer.py:56
↓ 7 callersMethod__init__
( self, model_arch: str, input_image_shape: int, map_feature_d
tbsim/models/rasterized_models.py:120
↓ 7 callersFunctionbatch_nd_transform_points_np
(points, Mat)
tbsim/utils/geometry_utils.py:80
↓ 7 callersFunctioncalc_distance_map
mark the image with manhattan distance to the drivable area Args: road_flag (torch.Tensor[B,W,H]): an image with 1 channel, 1 for drivabl
tbsim/utils/geometry_utils.py:404
↓ 7 callersMethodconvert_action_to_state_and_action
Apply dynamics on input action trajectory to get state+action trajectory Input: x_out: (batch_size, num_steps, 2). scaled
tbsim/models/diffuser.py:528
↓ 7 callersMethoddescale_traj
- traj: B x T x D
tbsim/models/diffuser.py:576
↓ 7 callersFunctiondraw_constraint
(ax, loc, rel_time, max_time, raster_from_world, world_from_agent, marker_color='r', marker_size=32.0, boundin
tbsim/utils/scene_edit_utils.py:1111
↓ 7 callersMethoddump
(self, filename = None)
tbsim/configs/config.py:172
↓ 7 callersMethodforward_prediction
(pred_map, obs_dict, mask_drivable=False, num_samples=None, clearance=None)
tbsim/algos/algos.py:292
↓ 7 callersMethodpredict
(self,obs,**kwargs)
tbsim/algos/algos.py:1480
↓ 7 callersFunctionsplit_agents_by_scene
(agent, agent_scene_index, all_scene_index)
tbsim/envs/env_metrics.py:89
↓ 7 callersFunctionstep_aggregate_per_scene
Aggregate per-step metrics for each scene. 1. if there are more than one agent per scene, aggregate their metrics for each scene using @agg_
tbsim/envs/env_metrics.py:61
↓ 7 callersFunctiontransform_coord_agents_to_world
(pos_pred, yaw_pred, data_batch)
tbsim/utils/trajdata_utils.py:550
↓ 7 callersMethodwrap_planner
(cls, model, **kwargs)
tbsim/policies/wrappers.py:166
↓ 6 callersMethod__init__
A basic Conditional Variational Autoencoder Network (C-VAE) Args: q_net (nn.Module): a model that encodes data (x) and c
tbsim/models/vaes.py:313
↓ 6 callersFunction_assert_shapes
Check the shapes of args required by metrics Args: ground_truth (np.ndarray): array of shape (batch)x(timesteps)x(2D coords)
tbsim/utils/metrics.py:24
↓ 6 callersFunctionbatch_nd_transform_points
(points, Mat)
tbsim/utils/geometry_utils.py:73
↓ 6 callersFunctionbatch_rotate_2D
(xy, theta)
tbsim/utils/geometry_utils.py:186
↓ 6 callersMethodcalculate_vel
(pos, yaw, dt, mask)
tbsim/dynamics/bicycle.py:109
↓ 6 callersFunctionconvert_state_to_state_and_action
Infer vel and action (acc, yawvel) from state (x, y, yaw) based on Unicycle. Note: Support both agent-centric and scene-centric (extr
tbsim/models/diffuser_helpers.py:685
↓ 6 callersMethodeval
(self)
tbsim/policies/hardcoded.py:102
↓ 6 callersMethodforward
(self, obs_dict, plan=None)
tbsim/algos/multiagent_algos.py:59
↓ 6 callersMethodgen_EC_edges
(ego_trajectories, agent_trajectories, ego_extents, agent_extents, raw_types, mask=None)
tbsim/utils/batch_utils.py:96
↓ 6 callersMethodget_ego_predictions
(pred_batch)
tbsim/models/multiagent_models.py:135
↓ 6 callersMethodget_observation
(self)
tbsim/envs/env_l5kit.py:269
↓ 6 callersMethodget_policy
(self, policy=None)
tbsim/evaluation/policy_composers.py:123
↓ 6 callersFunctionmap_tensor
Apply function @func to torch.Tensor objects in a nested dictionary or list or tuple. Args: x (dict or list or tuple): a possibl
tbsim/utils/tensor_utils.py:59
↓ 6 callersFunctiontrajdata2posyawspeed
Converts trajdata's state format to pos, yaw, and speed. Set Nans to 0s
tbsim/utils/trajdata_utils.py:66
↓ 6 callersFunctiontransform_agents_to_world
Converts local agent poses to global frame. Input: pos_pred: (num_agents, num_samp, time_steps, 2) yaw_pred: (num_agents, num
tbsim/utils/geometry_utils.py:458
↓ 6 callersFunctiontransform_coord_world_to_agent_i
(pos_pred, yaw_pred, data_batch, ind_i)
tbsim/utils/trajdata_utils.py:554
↓ 5 callersMethodbatch_to_target_all_agents
(data_batch)
tbsim/utils/batch_utils.py:80
↓ 5 callersFunctionconvert_scene_data_to_agent_coordinates
This will convert a scene-centric data batch to agent-centric coordinates keep_order_of_neighbors: if True, the order of neighbors (includin
tbsim/utils/trajdata_utils.py:1141
↓ 5 callersMethoddeepcopy
(self)
tbsim/configs/config.py:107
↓ 5 callersFunctionf
(tensor)
tbsim/utils/tensor_utils.py:358
↓ 5 callersMethodgenerate_edges
(raw_type, extents, pos_pred, yaw_pred)
tbsim/utils/batch_utils.py:88
↓ 5 callersFunctionget_box_world_coords
(pos, yaw, extent)
tbsim/utils/geometry_utils.py:33
↓ 5 callersMethodget_serialized_scene_buffer
scene_index: dict( action_positions=[num_agent, T, ...], action_yaws=[num_agent, T, ...],
tbsim/utils/rollout_logger.py:149
↓ 5 callersFunctiongoal_reaching_loss
Final step loss between gt and predicted trajectories (normally used in conjunction with a forward dynamics model) Args: predictions
tbsim/utils/loss_utils.py:328
↓ 5 callersFunctionindices_in_bounds
Get indices of elements for which the bounding box described by bounds intersects the one defined around center (square with side 2*half_side
tbsim/l5kit/vis_rasterizer.py:42
next →1–100 of 1,831, ranked by callers