mirror of
https://github.com/blakeblackshear/frigate.git
synced 2025-08-31 13:48:19 +02:00
* sdk_2.0_update * memryx docs: minor reorg * ran ruff * whoops, more ruff fixes * Fixes (#6) * Fixes and custom model path updated * ruff formatting * removed apt install from main * add comment about libgomp1 in install_deps --------- Co-authored-by: Abinila Siva <abinila.siva@memryx.com> Co-authored-by: Abinila Siva <163017635+abinila4@users.noreply.github.com>
48 lines
1.4 KiB
Bash
48 lines
1.4 KiB
Bash
#!/bin/bash
|
|
set -e # Exit immediately if any command fails
|
|
set -o pipefail
|
|
|
|
echo "Starting MemryX driver and runtime installation..."
|
|
|
|
# Detect architecture
|
|
arch=$(uname -m)
|
|
|
|
# Purge existing packages and repo
|
|
echo "Removing old MemryX installations..."
|
|
# Remove any holds on MemryX packages (if they exist)
|
|
sudo apt-mark unhold memx-* mxa-manager || true
|
|
sudo apt purge -y memx-* mxa-manager || true
|
|
sudo rm -f /etc/apt/sources.list.d/memryx.list /etc/apt/trusted.gpg.d/memryx.asc
|
|
|
|
# Install kernel headers
|
|
echo "Installing kernel headers for: $(uname -r)"
|
|
sudo apt update
|
|
sudo apt install -y dkms linux-headers-$(uname -r)
|
|
|
|
# Add MemryX key and repo
|
|
echo "Adding MemryX GPG key and repository..."
|
|
wget -qO- https://developer.memryx.com/deb/memryx.asc | sudo tee /etc/apt/trusted.gpg.d/memryx.asc >/dev/null
|
|
echo 'deb https://developer.memryx.com/deb stable main' | sudo tee /etc/apt/sources.list.d/memryx.list >/dev/null
|
|
|
|
# Update and install memx-drivers
|
|
echo "Installing memx-drivers..."
|
|
sudo apt update
|
|
sudo apt install -y memx-drivers
|
|
|
|
# ARM-specific board setup
|
|
if [[ "$arch" == "aarch64" || "$arch" == "arm64" ]]; then
|
|
echo "Running ARM board setup..."
|
|
sudo mx_arm_setup
|
|
fi
|
|
|
|
echo -e "\n\n\033[1;31mYOU MUST RESTART YOUR COMPUTER NOW\033[0m\n\n"
|
|
|
|
# Install other runtime packages
|
|
packages=("memx-accl" "mxa-manager")
|
|
for pkg in "${packages[@]}"; do
|
|
echo "Installing $pkg..."
|
|
sudo apt install -y "$pkg"
|
|
done
|
|
|
|
echo "MemryX installation complete!"
|