Installation issues on Mac Big Sur

First, I want to assure you that I have searched the forum and read the many posts with this or similar titles. I have been able to work through a number of issues with Node and npm but I am not yet at the finish line - I need some help.

I have a Mac running OS X Big Sur 11.6. I have installed the pre-reqs:

  • Homebrew installed
  • Python3 - 3.10.0 installed
  • Node v14.18.1 installed
  • npm 8.1.0 installed

I have un and re-installed edge-impulse-cli multiple times with and without --force

I have downloaded and attempted to run the install script for Macbut there is an issue with this script and I get the following error when I run it:

-bash: ./install-mac.sh: line 7: syntax error near unexpected token `)'
-bash: ./install-mac.sh: line 7: `		-u|--update-all) UPDATE="true"'

so, I tried running the commands in the script but there is conflict between the install script and the instructions page (script installs Python 2.7 while the instructions page says install Python 3). Since the install script won’t run, I decided to trust the instructions page and installed Python 3. Net is that the install script is not functional.

So, here is where I am at with the install. When I type:

npm install edge-impulse-cli -g --force

I get the following:

cmcclell-mac:ei-install-scripts-main chipmc$ npm install edge-impulse-cli -g --force

npm WARN using --force Recommended protections disabled.

npm WARN deprecated @zeit/dockerignore@0.0.5: "@zeit/dockerignore" is no longer maintained

npm WARN deprecated har-validator@5.1.5: this library is no longer supported

npm WARN deprecated request-promise@4.2.4: request-promise has been deprecated because it extends the now deprecated request package, see https://github.com/request/request/issues/3142

npm WARN deprecated uuid@3.4.0: Please upgrade to version 7 or higher. Older versions may use Math.random() in certain circumstances, which is known to be problematic. See https://v8.dev/blog/math-random for details.

npm WARN deprecated request@2.88.0: request has been deprecated, see https://github.com/request/request/issues/3142

added 295 packages, and audited 296 packages in 16s

12 packages are looking for funding

run `npm fund` for details

**6** vulnerabilities (5 **moderate**, 1 **high**)

To address all issues (including breaking changes), run:

npm audit fix --force

Run `npm audit` for details.

When I try to run the “npm audit fix --force” command I get:

cmcclell-mac:ei-install-scripts-main chipmc$ npm audit fix --force

npm WARN using --force Recommended protections disabled.

npm ERR! code ENOLOCK

npm ERR! audit This command requires an existing lockfile.

npm ERR! audit Try creating one first with: npm i --package-lock-only

npm ERR! audit Original error: loadVirtual requires existing shrinkwrap file

npm ERR! A complete log of this run can be found in:

npm ERR! /Users/chipmc/.npm/_logs/2021-10-21T13_24_12_875Z-debug.log

cmcclell-mac:ei-install-scripts-main chipmc$

From what I have read, it is not clear if any of these are a big deal and I could not find a solution to the missing lock file issue.

So, it looked like the install completed (albeit with some warnings) yet, when I type an edge impulse command, I get this:

cmcclell-mac:ei-install-scripts-main chipmc$ edge-impulse-daemon
-bash: edge-impulse-daemon: command not found

It felt like a PATH issue but I could not see any clear guidance on what the path should be in the troubleshooting section for the cli install.

I am very excited to start learning about machine vision and I think the Edge Impuse tool is fantastic. But, based on my experience and the number of “trouble with install” posts on this forum, I would suggest that more may need to be done to improve the new user experience.

I would appreciate any help you can give on this. Thank you, Chip

Hi @chipmc,

The CLI is installed in /usr/local/bin, which should be part of your PATH. It should look like this:

aureleq@MacBook-Pro-6 ~ % ls -l /usr/local/bin | grep edge-imp
lrwxr-xr-x   1 aureleq  wheel        56 Oct 18 12:30 edge-impulse-blocks -> ../lib/node_modules/edge-impulse-cli/build/cli/blocks.js
lrwxr-xr-x   1 aureleq  wheel        56 Oct 18 12:30 edge-impulse-daemon -> ../lib/node_modules/edge-impulse-cli/build/cli/daemon.js
lrwxr-xr-x   1 aureleq  wheel        64 Oct 18 12:30 edge-impulse-data-forwarder -> ../lib/node_modules/edge-impulse-cli/build/cli/data-forwarder.js
lrwxr-xr-x   1 aureleq  wheel        68 Oct 18 12:30 edge-impulse-framebuffer2jpg -> ../lib/node_modules/edge-impulse-cli/build/cli/framebuffer-to-jpg.js
lrwxr-xr-x   1 aureleq  wheel        63 Jun 16 09:39 edge-impulse-linux -> ../lib/node_modules/edge-impulse-linux/build/cli/linux/linux.js
lrwxr-xr-x   1 aureleq  wheel        64 Jun 16 09:39 edge-impulse-linux-runner -> ../lib/node_modules/edge-impulse-linux/build/cli/linux/runner.js
lrwxr-xr-x   1 aureleq  wheel        61 Oct 18 12:30 edge-impulse-run-impulse -> ../lib/node_modules/edge-impulse-cli/build/cli/run-impulse.js
lrwxr-xr-x   1 aureleq  wheel        58 Oct 18 12:30 edge-impulse-uploader -> ../lib/node_modules/edge-impulse-cli/build/cli/uploader.js
lrwxr-xr-x   1 aureleq  wheel        74 Oct 18 12:30 eta-flash-tool -> ../lib/node_modules/edge-impulse-cli/build/cli/eta-flash-tool/flashtool.js
lrwxr-xr-x   1 aureleq  wheel        76 Oct 18 12:30 himax-flash-tool -> ../lib/node_modules/edge-impulse-cli/build/cli/himax-flash-tool/flashtool.js

You can also check that scripts are in /usr/local/lib/node_modules/edge-impulse-cli/build/cli

Also thanks for your feedback about the platform! As you said some users experience issues to install the CLI, we’re doing some work to simplify the CLI setup to avoid the common pitfalls.

Aurelien

1 Like

Will update when the script fixes have been pushed, thank you!

1 Like