Sfoglia il codice sorgente

Move anime face model to root, ignore builds folder

ghorsington 4 anni fa
parent
commit
949e438043
3 ha cambiato i file con 2 aggiunte e 3 eliminazioni
  1. 1 2
      .gitignore
  2. 0 0
      animu.xml
  3. 1 1
      src/commands/facemorph.ts

+ 1 - 2
.gitignore

@@ -1,5 +1,4 @@
-*.js
-*.js.map
+build/
 
 *.sqlite
 

build/animu.xml → animu.xml


+ 1 - 1
src/commands/facemorph.ts

@@ -11,7 +11,7 @@ import { ObjectChain } from "lodash";
 
 const EMOTE_GUILD = "505333548694241281";
 
-const animeCascade = new cv.CascadeClassifier(path.resolve(__dirname, "../animu.xml"));
+const animeCascade = new cv.CascadeClassifier(path.resolve(process.cwd(), "animu.xml"));
 const faceCascade = new cv.CascadeClassifier(cv.HAAR_FRONTALFACE_ALT2);
 
 type ImageProcessor = (faces: cv.Rect[], data: Buffer) => Promise<Jimp>;