Skip to content

MMS Usage & Early Access to Preview Models

Using mms requires logging in with a Model Farm account. Please visit Model Farm account registration

System Dependency Configuration

Configure the AidLux Repository

bash
# Download the correct public key
sudo wget -O- https://archive.aidlux.com/ubuntu24/public.key | gpg --dearmor | sudo tee /etc/apt/trusted.gpg.d/private-aidlux.gpg > /dev/null

# Edit the source file
sudo vim /etc/apt/sources.list.d/private-aidlux.list

# Add the private key provided by AidLux to the source file
deb [arch=arm64 signed-by=/etc/apt/trusted.gpg.d/private-aidlux.gpg] https://archive.aidlux.com/ubuntu24 noble main

# Update the cache
sudo apt update

After the update, you can obtain the official AidLux SDK dependencies with the following command:

bash
sudo apt list | grep aid | grep unknown
bash
# Install software
# Must be installed first; not included with the system
sudo apt install python3 python3-pip libopencv-dev python3-opencv  net-tools
# Required before installing aidlite
sudo apt install aidlux-aistack-base aidrtcm

# Install aidlite and its dependencies
sudo apt install aid-lms aidlms-sdk aidlite-sdk cmake
sudo apt-get install libfmt-dev nlohmann-json3-dev
sudo apt install aidlite-*

# Enable DSP support
sudo apt-get install qcom-fastrpc1
sudo apt-get install qcom-fastrpc-dev

# Install the aidgen SDK
sudo apt install aidgen-qnn240-sdk

# Install the mms service
sudo apt install aid-mms

# Enable GPU support
sudo add-apt-repository ppa:ubuntu-qcom-iot/qcom-noble-ppa
sudo apt install qcom-adreno-cl1
sudo ln -s /usr/lib/aarch64-linux-gnu/libOpenCL.so.1 /usr/lib/aarch64-linux-gnu/libOpenCL.so

After installation, check that the aidlite and aidgen directories have been added under /usr/local/share.

Device Authorization

Obtain the Device SN Code

bash
cat  /sys/devices/soc0/serial_number

Obtain the License File

Provide the SN code to the Aplux technical staff to generate a device-specific License file, and place it under /etc/opt/aidlux/license/AidLuxLics.

MMS Usage

MMS is a component provided for Aplux board users. It allows users to log in to the Model Farm via the command line to query and download model files. The specific process is as follows:

  1. Log in
bash
mms login

# Enter your username: 
# Enter your password:

# A message will appear after entering the correct credentials:
# Login successfully.
  1. Model query
bash
# List all models
mms list

# Search for a model by name
mms list yolo
Model        Precision  Chipset           Backend
-----        ---------  -------           -------
YOLO-NAS-l   FP16       Qualcomm QCS8550  QNN2.29
YOLO-NAS-l   INT8       Qualcomm QCS6490  QNN2.29
YOLO-NAS-l   INT8       Qualcomm QCS8550  QNN2.29
YOLO-NAS-l   W8A16      Qualcomm QCS6490  QNN2.29
YOLO-NAS-l   W8A16      Qualcomm QCS8550  QNN2.29
YOLO-NAS-m   FP16       Qualcomm QCS8550  QNN2.29
YOLO-NAS-m   INT8       Qualcomm QCS6490  QNN2.29
YOLO-NAS-m   INT8       Qualcomm QCS8550  QNN2.29
  1. Model download
bash
# -m: Model name
# -p: Precision
# -c: Chipset
# -b: QNN version
# Download the yolov6l model with INT8 precision, optimized for the QCS8550 chipset, using the QNN2.23 inference framework.
mms get -m yolov6l -p int8 -c qcs8550 -b qnn2.23


Downloading model from https://aiot.aidlux.com to directory: /var/opt/modelfarm_models

Downloading [yolov6l_qcs8550_qnn2.23_int8_aidlite.zip] ... done! [40.45MB in 375ms; 81.51MB/s]

Download complete!

Accessing Preview Model Resources

Models in the Preview section of the Model Farm do not support direct web downloads. Developers can download preview models on Aplux boards using the mms command. The following example demonstrates how to retrieve the MobileClip2-S3 model.

  1. Log in via mms
bash
mms login

# Enter your username: 
# Enter your password:

# A message will appear after entering the correct credentials:
# Login successfully.
  1. Search for the model
bash
mms list mobileclip # Supports keyword search

# Expected output:
Model           Precision  Chipset           Backend
-----           ---------  -------           -------
MobileClip-S2   FP16       Qualcomm QCS8550  QNN2.31
MobileClip2-S3  FP16       Qualcomm QCS8550  QNN2.36
  1. Download MobileClip2-S3
bash
# -m: Model name
# -p: Precision
# -c: Chipset
# -b: QNN version
mms get -m MobileClip2-S3 -p fp16 -c qcs8550 -b qnn2.36

# Model resources are downloaded to /var/opt/modelfarm_models by default.