- AMD Kria KV260
- Logitech C920 webcam
Start from Ubuntu 22.04 on KV260
sudo apt-get install -y \
python3-boto3
git clone https://github.com/Xilinx/Kria-PYNQ.git
cd Kria-PYNQ
sudo bash ./install.sh -b KV260; # This will take about 25 minutes
Then login as root
sudo su
and complete the installation as root
. /home/ubuntu/Kria-PYNQ/pynq/sdbuild/packages/xrt/xrt_setup.sh
. /etc/profile.d/pynq_venv.sh
pip3 install pynq-dpu --no-build-isolation
then copy the xmodel file TODO!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
- Must have an AWS IAM user with AmazonRekognition* permission policies (add a group with all those policies then add user to group)
- Set up target environment to communicate with aws
mkdir -p ~/.aws
touch ~/.aws/credentials
touch ~/.aws/config
where ~/.aws/credentials
looks like
[default]
aws_access_key_id = your_access_key_id
aws_secret_access_key = your_secret_access_key
and ~/.aws/config
looks like
[default]
region = your_aws_region
see https://docs.aws.amazon.com/pdfs/rekognition/latest/dg/rekognition-dg.pdf#what-is
source /home/ubuntu/Kria-PYNQ/pynq/sdbuild/packages/xrt/xrt_setup.sh
source /etc/profile.d/pynq_venv.sh
./cloud.py -h
For example, to detect faces using an image on disk
./cloud.py --print_duration --display --test_image ./irishterrier-696543.jpg --algorithm detect_faces
or to run on the live camera
./cloud.py --display
- Login as root
sudo su
- As root, setup the environment
. /home/ubuntu/Kria-PYNQ/pynq/sdbuild/packages/xrt/xrt_setup.sh
. /etc/profile.d/pynq_venv.sh
xauth add $(xauth -f ~ubuntu/.Xauthority list | tail -1)
- Run the script
./edge.py -h
For example, to run the algorithm using an image on disk, print information, and display the result
./edge.py --print_duration --display --test_image ./irishterrier-696543.jpg
or to run on the live camera
./edge.py --display