File tree Expand file tree Collapse file tree 1 file changed +4
-2
lines changed Expand file tree Collapse file tree 1 file changed +4
-2
lines changed Original file line number Diff line number Diff line change @@ -1544,7 +1544,7 @@ class CatTensors(Transform):
1544
1544
Args:
1545
1545
keys_in (Sequence of str): keys to be concatenated
1546
1546
out_key: key of the resulting tensor.
1547
- dim (int, optional): dimension along which the contenation will occur.
1547
+ dim (int, optional): dimension along which the concatenation will occur.
1548
1548
Default is -1.
1549
1549
del_keys (bool, optional): if True, the input values will be deleted after
1550
1550
concatenation. Default is True.
@@ -1575,13 +1575,15 @@ class CatTensors(Transform):
1575
1575
def __init__ (
1576
1576
self ,
1577
1577
keys_in : Optional [Sequence [str ]] = None ,
1578
- out_key : str = "observation_vector " ,
1578
+ out_key : str = "next_observation_vector " ,
1579
1579
dim : int = - 1 ,
1580
1580
del_keys : bool = True ,
1581
1581
unsqueeze_if_oor : bool = False ,
1582
1582
):
1583
1583
if keys_in is None :
1584
1584
raise Exception ("CatTensors requires keys to be non-empty" )
1585
+ if type (out_key ) != str :
1586
+ raise Exception ("CatTensors requires out_key to be of type string" )
1585
1587
super ().__init__ (keys_in = keys_in )
1586
1588
if not out_key .startswith ("next_" ) and all (
1587
1589
key .startswith ("next_" ) for key in keys_in
You can’t perform that action at this time.
0 commit comments