Rate this Page

torch.fx.experimental.migrate_gradual_types.constraint_transformation.gen_lists_of_dims#

torch.fx.experimental.migrate_gradual_types.constraint_transformation.gen_lists_of_dims(num_tensors, dim_size, counter)[source]#

Generate lists of DVar to represent tensor dimensions :param num_tensors: the required number of tensors :param dim_size: the number of dimensions for each tensor :param counter: variable tracking

Returns: A list of a list of tensor dimensions

Return type:

tuple[list[list[DVar]], int]