MCPcopy Create free account
hub / github.com/pytorch/pytorch / get

Method get

scripts/release_notes/common.py:316–321  ·  view source on GitHub ↗
(self, commit)

Source from the content-addressed store, hash-verified

314 os.makedirs(Path(path).parent, exist_ok=True)
315
316 def get(self, commit):
317 if commit not in self.data.keys():
318 # Fetch and cache the data
319 self.data[commit] = get_features(commit)
320 self.write_to_disk()
321 return self.data[commit]
322
323 def read_from_disk(self):
324 with open(self.path, "r") as f:

Callers 7

read_from_diskMethod · 0.45
gen_commitMethod · 0.45
rerun_with_new_filtersFunction · 0.45
forwardMethod · 0.45
featuresMethod · 0.45
get_tokenFunction · 0.45
github_dataFunction · 0.45

Calls 3

write_to_diskMethod · 0.95
get_featuresFunction · 0.85
keysMethod · 0.45

Tested by

no test coverage detected