MCPcopy Index your code
hub / github.com/SooLab/CGFormer / write

Method write

utils/misc.py:243–251  ·  view source on GitHub ↗
(self, buf)

Source from the content-addressed store, hash-verified

241 self.caller_names = caller_names
242
243 def write(self, buf):
244 full_name = get_caller_name(depth=1)
245 module_name = full_name.rsplit(".", maxsplit=-1)[0]
246 if module_name in self.caller_names:
247 for line in buf.rstrip().splitlines():
248 # use caller level log
249 logger.opt(depth=2).log(self.level, line.rstrip())
250 else:
251 sys.__stdout__.write(buf)
252
253 def flush(self):
254 pass

Callers 4

http_getFunction · 0.80
save_vocabularyMethod · 0.80
save_pretrainedMethod · 0.80
to_json_fileMethod · 0.80

Calls 1

get_caller_nameFunction · 0.85

Tested by

no test coverage detected