blib-la / LoRAdo

LoRAdo is a UI that allows easy creation of LoRAs for stable diffussion
GNU Affero General Public License v3.0
25 stars 1 forks source link

[BUG]: Error during install #1

Closed uarefans closed 1 year ago

uarefans commented 1 year ago

Describe the bug Error while npm install

Expected behavior No error

Screenshots

C:\Users\new\LoRAdo>npm install
npm WARN deprecated @types/unsplash-js@7.0.0: This is a stub types definition. unsplash-js provides its own type definitions, so you do not need this installed.
npm ERR! code 1
npm ERR! path C:\Users\new\LoRAdo\node_modules\@tensorflow\tfjs-node
npm ERR! command failed
npm ERR! command C:\Windows\system32\cmd.exe /d /s /c node scripts/install.js
npm ERR! CPU-windows-4.10.0.zip
npm ERR! https://storage.googleapis.com/tensorflow/libtensorflow/libtensorflow-cpu-windows-x86_64-2.9.1.zip
npm ERR! * Downloading libtensorflow
npm ERR!
npm ERR! * Building TensorFlow Node.js bindings
npm ERR! symlink ./lib/napi-v9 failed:  Error: Command failed: node scripts/deps-stage.js symlink ./lib/napi-v9
npm ERR!   * Symlink of lib\napi-v9\tensorflow.dll failed, creating a copy on disk.
npm ERR! node:internal/process/promises:288
npm ERR!             triggerUncaughtException(err, true /* fromPromise */);
npm ERR!             ^
npm ERR!
npm ERR! [Error: ENOENT: no such file or directory, copyfile 'C:\Users\new\LoRAdo\node_modules\@tensorflow\tfjs-node\deps\lib\tensorflow.dll' -> 'C:\Users\new\LoRAdo\node_modules\@tensorflow\tfjs-node\lib\napi-v9\tensorflow.dll'] {
npm ERR!   errno: -4058,
npm ERR!   code: 'ENOENT',
npm ERR!   syscall: 'copyfile',
npm ERR!   path: 'C:\\Users\\new\\LoRAdo\\node_modules\\@tensorflow\\tfjs-node\\deps\\lib\\tensorflow.dll',
npm ERR!   dest: 'C:\\Users\\new\\LoRAdo\\node_modules\\@tensorflow\\tfjs-node\\lib\\napi-v9\\tensorflow.dll'
npm ERR! }
npm ERR!
npm ERR! Node.js v18.17.0
npm ERR!
npm ERR!     at ChildProcess.exithandler (node:child_process:419:12)
npm ERR!     at ChildProcess.emit (node:events:514:28)
npm ERR!     at maybeClose (node:internal/child_process:1091:16)
npm ERR!     at ChildProcess._handle.onexit (node:internal/child_process:302:5) {
npm ERR!   code: 1,
npm ERR!   killed: false,
npm ERR!   signal: null,
npm ERR!   cmd: 'node scripts/deps-stage.js symlink ./lib/napi-v9'
npm ERR! }

npm ERR! A complete log of this run can be found in: C:\Users\new\AppData\Local\npm-cache\_logs\2023-08-15T12_22_27_806Z-debug-0.log

Versions (please complete the following information):

Additional context Log file in attachment 2023-08-15T12_22_27_806Z-debug-0.log

pixelass commented 1 year ago

Just linking for reference

uarefans commented 1 year ago

error gone when using

npm install -g node-gyp
npm install --save-exact @tensorflow/tfjs-node@3.1.0

but have other issue when

npm run build

error

when fixing with update .eslintrc.json under rules

    "prettier/prettier": ["warn",  {"endOfLine": "auto"}],

i can run npm run build but when try upload files and click prepare showing error

error2

uarefans commented 1 year ago

solve with

  1. downgrade nodejs to 18.14.2
  2. edit .eslintrc.json under rules "prettier/prettier": ["error", {"endOfLine": "auto"}],
  3. Run npm install & npm run build then npm start
  4. Work perfectly on chrome browser

Notes: i'm using firefox and chrome, when in firefox, box detector not working but auto download tiny_face_detector_model.bin but in chrome works perfectly

Thank you and my problem solved

pixelass commented 1 year ago

thank you for researching this I will test with later versions of node and look into the EOL issue.

pixelass commented 1 year ago

@uarefans I looked into this and it should also work with node 18.7.1 now. I tested it locally and was able to reproduce the error from above when switching to node 18.7.1. After adjusting the version of tfjs-node as mentiopned here: https://github.com/tensorflow/tfjs/issues/7881, everything istalled fine.

I guess tensorflow hasverioning issues and missing binaries for v4.

uarefans commented 1 year ago

thank you, i try 10 hours ago using other pc and node 18.7.1 but still error i forget to capture the log, "something about tensorflow module" again but when downgrade again using node 18.14.2 error gone and works

pixelass commented 1 year ago

@uarefans my bad. I meant 18.17.1 (just checking)

uarefans commented 1 year ago

@pixelass my bad too, my node version 18.17.1 before not 18.7.1 but didn't work, i'll try fresh install again later to make sure.

pixelass commented 1 year ago

Several people are having this issue. We've tested 18.5.0 too and it seemed to work. We'll start to add tests to verify the install process.