mirror of
https://github.com/arthur-pbty/xiao.git
synced 2026-06-24 22:34:46 +02:00
Increase image size limit
This commit is contained in:
@@ -58,7 +58,7 @@ module.exports = class AnimeEyesCommand extends Command {
|
|||||||
}
|
}
|
||||||
|
|
||||||
async detect(imgData) {
|
async detect(imgData) {
|
||||||
if (Buffer.byteLength(imgData.body) >= 2e+6) return 'size';
|
if (Buffer.byteLength(imgData.body) >= 4e+6) return 'size';
|
||||||
tfnode.setBackend('tensorflow');
|
tfnode.setBackend('tensorflow');
|
||||||
const image = tfnode.node.decodeImage(imgData);
|
const image = tfnode.node.decodeImage(imgData);
|
||||||
tfnode.setBackend('cpu');
|
tfnode.setBackend('cpu');
|
||||||
|
|||||||
Reference in New Issue
Block a user