Skip to content

Commit b637fb3

Browse files
bowiechenmeta-codesync[bot]
authored andcommitted
apply Black 25.11.0 style in fbcode (72/92)
Summary: Formats the covered files with pyfmt. paintitblack Reviewed By: itamaro Differential Revision: D90476322 fbshipit-source-id: e689aa40511799087010490a2ebe5260d41130c8
1 parent 9b22ce8 commit b637fb3

85 files changed

Lines changed: 66 additions & 202 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

pearl/action_representation_modules/action_representation_module.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,6 @@
1010
from abc import ABC, abstractmethod
1111

1212
import torch
13-
1413
import torch.nn as nn
1514

1615

pearl/action_representation_modules/binary_action_representation_module.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,6 @@
1010
from typing import List
1111

1212
import torch
13-
1413
from pearl.action_representation_modules.action_representation_module import (
1514
ActionRepresentationModule,
1615
)

pearl/action_representation_modules/one_hot_action_representation_module.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,6 @@
1111

1212
import torch
1313
import torch.nn.functional as F
14-
1514
from pearl.action_representation_modules.action_representation_module import (
1615
ActionRepresentationModule,
1716
)

pearl/api/action_result.py

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,9 +11,7 @@
1111
from typing import Any
1212

1313
from pearl.api.action_space import ActionSpace
14-
1514
from pearl.api.observation import Observation
16-
1715
from pearl.api.reward import Reward
1816

1917

pearl/api/space.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,6 @@
1212
from abc import ABC, abstractmethod
1313

1414
import torch
15-
1615
from pearl.api.action import Action
1716
from torch import Tensor
1817

pearl/history_summarization_modules/history_summarization_module.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,6 @@
1111

1212
import torch
1313
import torch.nn as nn
14-
1514
from pearl.api.action import Action
1615
from pearl.api.history import History
1716
from pearl.api.observation import Observation

pearl/history_summarization_modules/identity_history_summarization_module.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,6 @@
1010
from typing import List
1111

1212
import torch
13-
1413
from pearl.api.action import Action
1514
from pearl.api.history import History
1615
from pearl.api.observation import Observation

pearl/history_summarization_modules/transformer_history_summarization_module.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -222,9 +222,9 @@ def forward(self, x: torch.Tensor) -> torch.Tensor:
222222
x: [B, T, input_dim] — batch of sequences of (action, observation) pairs.
223223
Returns: [B, d_model] — representation of the last token for each sequence.
224224
"""
225-
assert (
226-
x.dim() == 3 and x.size(-1) == self.input_dim
227-
), f"Expected [B, T, {self.input_dim}], got {tuple(x.shape)}"
225+
assert x.dim() == 3 and x.size(-1) == self.input_dim, (
226+
f"Expected [B, T, {self.input_dim}], got {tuple(x.shape)}"
227+
)
228228

229229
return self._encode_last_token(x)
230230

pearl/neural_networks/common/utils.py

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,9 +13,7 @@
1313

1414
import torch
1515
import torch.nn as nn
16-
1716
from pearl.neural_networks.common.residual_wrapper import ResidualWrapper
18-
1917
from torch.func import stack_module_state
2018

2119

pearl/neural_networks/common/value_networks.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,6 @@
1616

1717
import torch
1818
import torch.nn as nn
19-
2019
from pearl.neural_networks.common.utils import (
2120
compute_output_dim_model_cnn,
2221
conv_block,

0 commit comments

Comments
 (0)