MCPcopy Create free account
hub / github.com/OpenBitSys/BitDistiller / __len__

Method __len__

data/generation/single_generate.py:105–106  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

103 self.labels = data_dict["labels"]
104
105 def __len__(self):
106 return len(self.input_ids)
107
108 def __getitem__(self, i) -> Dict[str, torch.Tensor]:
109 return dict(input_ids=self.input_ids[i], labels=self.labels[i], id=i)

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected