MCPcopy Create free account
hub / github.com/OpenBMB/MiniCPM-V / __init__

Method __init__

chat.py:164–167  ·  view source on GitHub ↗
(self, model_path)

Source from the content-addressed store, hash-verified

162
163class MiniCPMV2_5:
164 def __init__(self, model_path) -> None:
165 self.model = AutoModel.from_pretrained(model_path, trust_remote_code=True).to(dtype=torch.float16)
166 self.tokenizer = AutoTokenizer.from_pretrained(model_path, trust_remote_code=True)
167 self.model.eval().cuda()
168
169 def chat(self, input):
170 try:

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected