MCPcopy Create free account
hub / github.com/MoonInTheRiver/DiffSinger / add_item

Method add_item

utils/indexed_datasets.py:47–50  ·  view source on GitHub ↗
(self, item)

Source from the content-addressed store, hash-verified

45 self.byte_offsets = [0]
46
47 def add_item(self, item):
48 s = pickle.dumps(item)
49 bytes = self.out_file.write(s)
50 self.byte_offsets.append(self.byte_offsets[-1] + bytes)
51
52 def finalize(self):
53 self.out_file.close()

Callers 2

process_dataMethod · 0.95

Calls

no outgoing calls

Tested by

no test coverage detected