mirror of
https://github.com/nomic-ai/gpt4all.git
synced 2024-09-19 23:35:41 +00:00
Debug
This commit is contained in:
parent
7c7864ac72
commit
19dd6c7635
@ -18,8 +18,14 @@
|
|||||||
|
|
||||||
void* load_gpt4all_model(const char *fname, int n_threads) {
|
void* load_gpt4all_model(const char *fname, int n_threads) {
|
||||||
// load the model
|
// load the model
|
||||||
auto gptj4all = llmodel_model_create(fname);
|
llmodel_error new_error{};
|
||||||
|
fprintf(stderr, "%s: fname '%s'\n",
|
||||||
|
__func__, fname);
|
||||||
|
auto gptj4all = llmodel_model_create2(fname, "auto", &new_error);
|
||||||
if (gptj4all == NULL ){
|
if (gptj4all == NULL ){
|
||||||
|
fprintf(stderr, "%s: error '%s'\n",
|
||||||
|
__func__, new_error.message);
|
||||||
|
|
||||||
return nullptr;
|
return nullptr;
|
||||||
}
|
}
|
||||||
llmodel_setThreadCount(gptj4all, n_threads);
|
llmodel_setThreadCount(gptj4all, n_threads);
|
||||||
|
Loading…
Reference in New Issue
Block a user