Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 3 additions & 1 deletion colossalai/nn/layer/utils/common.py
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,8 @@


class CheckpointModule(nn.Module):
def __init__(self, checkpoint: bool = True, offload : bool = False):

def __init__(self, checkpoint: bool = True, offload: bool = False):
super().__init__()
self.checkpoint = checkpoint
self._use_checkpoint = checkpoint
Expand Down Expand Up @@ -78,6 +79,7 @@ def get_tensor_parallel_mode():


def _ntuple(n):

def parse(x):
if isinstance(x, collections.abc.Iterable):
return x
Expand Down