fix: unintended local_files_only in loading the tokenizer
This commit is contained in:
parent
f70401846a
commit
46191cfd56
@ -18,8 +18,7 @@ export async function initializeModels() {
|
|||||||
}
|
}
|
||||||
|
|
||||||
try {
|
try {
|
||||||
const tokenizerConfig = { local_files_only: true };
|
tokenizer = await AutoTokenizer.from_pretrained(tokenizerModel);
|
||||||
tokenizer = await AutoTokenizer.from_pretrained(tokenizerModel, tokenizerConfig);
|
|
||||||
|
|
||||||
const [classifierSession, embeddingSession] = await Promise.all([
|
const [classifierSession, embeddingSession] = await Promise.all([
|
||||||
ort.InferenceSession.create(onnxClassifierPath),
|
ort.InferenceSession.create(onnxClassifierPath),
|
||||||
|
@ -18,6 +18,7 @@ export async function insertLatestVideos(
|
|||||||
}
|
}
|
||||||
logger.log(`Latest video in the database: ${new Date(latestVideoTimestamp).toISOString()}`, "net", "fn:insertLatestVideos()")
|
logger.log(`Latest video in the database: ${new Date(latestVideoTimestamp).toISOString()}`, "net", "fn:insertLatestVideos()")
|
||||||
const videoIndex = await getVideoPositionInNewList(latestVideoTimestamp);
|
const videoIndex = await getVideoPositionInNewList(latestVideoTimestamp);
|
||||||
|
logger.log(`Position of the video in the latest list: ${videoIndex}`, "net", "fn:insertLatestVideos()")
|
||||||
if (videoIndex == null) {
|
if (videoIndex == null) {
|
||||||
logger.error("Cannot locate the video through bisect.", "net", "fn:insertLatestVideos()");
|
logger.error("Cannot locate the video through bisect.", "net", "fn:insertLatestVideos()");
|
||||||
return null
|
return null
|
||||||
|
Loading…
Reference in New Issue
Block a user