jetson-examples 0.1.4__py3-none-any.whl → 0.1.5__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: jetson-examples
3
- Version: 0.1.4
3
+ Version: 0.1.5
4
4
  Summary: Running Gen AI models and applications on NVIDIA Jetson devices with one-line command
5
5
  Author-email: luozhixin <zhixin.luo@seeed.cc>
6
6
  Project-URL: Homepage, https://github.com/Seeed-Projects/jetson-examples
@@ -23,11 +23,11 @@ License-File: LICENSE
23
23
 
24
24
  This repository provides examples for running AI models and applications on [NVIDIA Jetson devices](https://www.seeedstudio.com/reComputer-J4012-p-5586.html) with a single command.
25
25
 
26
- This repo builds upon the work of the [jetson-containers](https://github.com/dusty-nv/jetson-containers), which provides a modular container build system for various AI/ML packages on NVIDIA Jetson devices.
26
+ This repo builds upon the work of the [jetson-containers](https://github.com/dusty-nv/jetson-containers), [ultralytics](https://github.com/ultralytics/ultralytics) and other excellent projects.
27
27
 
28
28
  ## Features
29
29
  - 🚀 **Easy Deployment:** Deploy state-of-the-art AI models on Jetson devices in one line.
30
- - 🔄 **Versatile Examples:** Supports text generation, image generation, vision transformers, computer vision and so on.
30
+ - 🔄 **Versatile Examples:** Supports text generation, image generation, computer vision and so on.
31
31
  - ⚡ **Optimized for Jetson:** Leverages Nvidia Jetson hardware for efficient performance.
32
32
 
33
33
 
@@ -60,9 +60,11 @@ Here are some examples that can be run:
60
60
 
61
61
  | Example | Type | Model/Data Size | Docker Image Size | Command |
62
62
  | ------------------------------------------------ | ------------------------ | --------------- | ---------- | --------------------------------------- |
63
- | 🆕 [yolov10](/reComputer/scripts/yolov10/README.md) | Computer Vision | 7.2M | 5.74 GB | `reComputer run yolov10` |
64
- | 🆕 llama3 | Text (LLM) | 4.9GB | 10.5GB | `reComputer run llama3` |
65
- | 🆕 [ollama](https://github.com/ollama/ollama) | Inference Server | * | 10.5GB | `reComputer run ollama` |
63
+ | 🆕 llama-factory | Finetune LLM | | 13.5GB | `reComputer run llama-factory` |
64
+ | 🆕 [depth-anything](/reComputer/scripts/depth-anything/README.md) |Computer Vision | | 12.9GB | `reComputer run depth-anything` |
65
+ | [yolov10](/reComputer/scripts/yolov10/README.md) | Computer Vision | 7.2M | 5.74 GB | `reComputer run yolov10` |
66
+ | llama3 | Text (LLM) | 4.9GB | 10.5GB | `reComputer run llama3` |
67
+ | [ollama](https://github.com/ollama/ollama) | Inference Server | * | 10.5GB | `reComputer run ollama` |
66
68
  | LLaVA | Text + Vision (VLM) | 13GB | 14.4GB | `reComputer run llava` |
67
69
  | Live LLaVA | Text + Vision (VLM) | 13GB | 20.3GB | `reComputer run live-llava` |
68
70
  | stable-diffusion-webui | Image Generation | 3.97G | 7.3GB | `reComputer run stable-diffusion-webui` |
@@ -71,7 +73,7 @@ Here are some examples that can be run:
71
73
  | whisper | Audio | 1.5GB | 6.0GB | `reComputer run whisper` |
72
74
  | [yolov8-rail-inspection](/reComputer/scripts/yolov8-rail-inspection/readme.md) |Computer Vision | 6M | 13.8GB | `reComputer run yolov8-rail-inspection` |
73
75
  | [ultralytics-yolo](/reComputer/scripts/ultralytics-yolo/README.md) |Computer Vision | | 15.4GB | `reComputer run ultralytics-yolo` |
74
- | [depth-anything](/reComputer/scripts/depth-anything/README.md) |Computer Vision | | 12.9GB | `reComputer run depth-anything` |
76
+
75
77
 
76
78
  > Note: You should have enough space to run example, like `LLaVA`, at least `27.4GB` totally
77
79
 
@@ -84,13 +86,14 @@ We welcome contributions to improve jetson-examples! If you have an example you'
84
86
 
85
87
  ## TODO List
86
88
 
89
+ - [x] detect host environment and install what we need
90
+ - [x] all type jetson support checking list
91
+ - [x] try jetpack 6.0
87
92
  - [ ] check disk space enough or not before run
88
93
  - [ ] allow to setting some configs, such as `BASE_PATH`
89
- - [ ] detect host environment and install what we need
90
94
  - [ ] support jetson-containers update
91
- - [ ] all type jetson support checking list
92
95
  - [ ] better table to show example's difference
93
- - [ ] try jetpack 6.0
96
+
94
97
 
95
98
 
96
99
  ## License
@@ -1,4 +1,4 @@
1
- reComputer/__init__.py,sha256=Wzf5T3NBDfhQoTnhnRNHSlAsE0XMqbclXG-M81Vas70,22
1
+ reComputer/__init__.py,sha256=XEqb2aiIn8fzGE68Mph4ck1FtQqsR_am0wRWvrYPffQ,22
2
2
  reComputer/main.py,sha256=A9otIJQ69cwKq6ZrRKPMRuR5Xe5uHHtUy-KwcK_9YZM,2088
3
3
  reComputer/scripts/check.sh,sha256=cUMwAjHpgJoaD5a8gTLJG7QWjF9CyKPgQ-ewRNK3FD8,127
4
4
  reComputer/scripts/clean.sh,sha256=TlGas1IKqSX7MEkZe4VvCQJgjDNEvfQyuAeXtKraNMA,898
@@ -12,7 +12,7 @@ reComputer/scripts/audiocraft/init.sh,sha256=ktAKm4XFtJYntnSR-oAK4G5OhCSSoKw511m
12
12
  reComputer/scripts/audiocraft/run.sh,sha256=b0kjEeZnA5diQw6vjyrkOX-Svs5XVKGt0ABbWtZsZEs,160
13
13
  reComputer/scripts/depth-anything/Dockerfile,sha256=gJ2Q1g2E06_z4hy9C-m1bA4X2IMqRWuo42izFfQ_E5Y,279
14
14
  reComputer/scripts/depth-anything/LICENSE,sha256=feSgondqafLDgk7Dp9gnVBE5Y9K5X9mal_DGYKALzXQ,1073
15
- reComputer/scripts/depth-anything/README.md,sha256=UDfEoOnuwvNLo-huhweyk-XXh0aQHczcKP58qe7Rez0,4211
15
+ reComputer/scripts/depth-anything/README.md,sha256=nHFcFIEZyoy3_n7bFuQ_3zT3IKRwLmRkxuXj9YE4sWw,4205
16
16
  reComputer/scripts/depth-anything/clean.sh,sha256=81oScb0iXcFQ6-3X9bfIJRcE6hBuVETGDyNbQwMhQ7Q,75
17
17
  reComputer/scripts/depth-anything/run.sh,sha256=m8g6LHQHPssKuOftLil0y3IbZaIwFIkHGt_laecCRBs,315
18
18
  reComputer/scripts/depth-anything/images/Autonomous Driving.png,sha256=oHdvvCyA5-ifHNWz4MxnBGT4HSy5Bbud9vbxlilS2-w,331869
@@ -24,6 +24,12 @@ reComputer/scripts/depth-anything/images/WebUI.png,sha256=HtlUbq6KSOqR6vV1n7mFaV
24
24
  reComputer/scripts/depth-anything/images/teaser.png,sha256=J1VpUd71nshdWgZ1dS0LUl9ppJn-Rm2-ZPX9YuM4C38,5657444
25
25
  reComputer/scripts/live-llava/init.sh,sha256=ktAKm4XFtJYntnSR-oAK4G5OhCSSoKw511mR9qk6xGw,428
26
26
  reComputer/scripts/live-llava/run.sh,sha256=4sWld5d8Fkr9GUVqLH2S1RyOKOjobhjojSzuJu8EuCg,10137
27
+ reComputer/scripts/llama-factory/README.md,sha256=N727Q8X-OGo-_d4ZIAhwbWtcOyjto0XwfzmI2Zw8wHg,2449
28
+ reComputer/scripts/llama-factory/clean.sh,sha256=cRpFDKCkKDCgaCoXdmF60dQ_RLAcIHbYZ5w-8PLKRr8,133
29
+ reComputer/scripts/llama-factory/init.sh,sha256=FAaIlBQxLdenS6aW8Vpo5OqBZgV0NmkrCpkbJMwkwtU,1633
30
+ reComputer/scripts/llama-factory/run.sh,sha256=NsxvjSkwFQ-b5DoPRN5DlCYsyvq1_wpZmubVN9y4nQs,231
31
+ reComputer/scripts/llama-factory/assets/llama-factory-Jetson.png,sha256=bUoDJWCiGfGRM_cQBEve-7nJyJFxCS5E0ekBcc1fpUg,574732
32
+ reComputer/scripts/llama-factory/assets/webui.png,sha256=RXaMyX3cIqZVoO27z5kn0rmbfEapdMuWN2JmPZlJlB0,419226
27
33
  reComputer/scripts/llama3/init.sh,sha256=ktAKm4XFtJYntnSR-oAK4G5OhCSSoKw511mR9qk6xGw,428
28
34
  reComputer/scripts/llama3/run.sh,sha256=IkHvMwh_U8fp7AH2qWFUMWywHZDbZKHlp8ODzfHgqBQ,328
29
35
  reComputer/scripts/llava/clean.sh,sha256=7t2SIxj6_elOpHxtTjl9ofnU5d9Ir2r5eyNAj6lAI68,70
@@ -65,9 +71,9 @@ reComputer/scripts/yolov8:detect/README.txt,sha256=gLAXjOR1X9gXJM0XA0c1P12nz81zv
65
71
  reComputer/scripts/yolov8:detect/app.py,sha256=63o2icb_av9owTBW6nL6wJfXdYEyZRt8feBL6YqrWTw,1307
66
72
  reComputer/scripts/yolov8:detect/run.sh,sha256=iq5o5iy2iPaUfC471sOWY4HhYWIOZ1geauqNQ-fg-2Y,130
67
73
  reComputer/scripts/yolov8:detect/templates/index.html,sha256=Q0mRmqax_F4cZq8Zau_JLtwvCpFH_Al6lUisu9Uaids,524
68
- jetson_examples-0.1.4.dist-info/LICENSE,sha256=ac_LOi8ChcJhymEfBulX98Y06wTI2IMcQnqCXZ5yay4,1066
69
- jetson_examples-0.1.4.dist-info/METADATA,sha256=WsQuClajNisJEBXofJwR4O3A4LZdY6wTfi4e_tQiBPE,5279
70
- jetson_examples-0.1.4.dist-info/WHEEL,sha256=GJ7t_kWBFywbagK5eo9IoUwLW6oyOeTKmQ-9iHFVNxQ,92
71
- jetson_examples-0.1.4.dist-info/entry_points.txt,sha256=5-OdcBifoDjVXE9KjNoN6tQa8l_XSXhdbBEgL2hxeDM,58
72
- jetson_examples-0.1.4.dist-info/top_level.txt,sha256=SI-liiUOkoGwOJfMP7d7k63JKgdcbiEj6DEC8QIKI90,11
73
- jetson_examples-0.1.4.dist-info/RECORD,,
74
+ jetson_examples-0.1.5.dist-info/LICENSE,sha256=ac_LOi8ChcJhymEfBulX98Y06wTI2IMcQnqCXZ5yay4,1066
75
+ jetson_examples-0.1.5.dist-info/METADATA,sha256=389saGoBSnNuJzwFBxj07iucvIAQgHbJcKSR0FkY9lY,5323
76
+ jetson_examples-0.1.5.dist-info/WHEEL,sha256=y4mX-SOX4fYIkonsAGA5N0Oy-8_gI4FXw5HNI1xqvWg,91
77
+ jetson_examples-0.1.5.dist-info/entry_points.txt,sha256=5-OdcBifoDjVXE9KjNoN6tQa8l_XSXhdbBEgL2hxeDM,58
78
+ jetson_examples-0.1.5.dist-info/top_level.txt,sha256=SI-liiUOkoGwOJfMP7d7k63JKgdcbiEj6DEC8QIKI90,11
79
+ jetson_examples-0.1.5.dist-info/RECORD,,
@@ -1,5 +1,5 @@
1
1
  Wheel-Version: 1.0
2
- Generator: bdist_wheel (0.43.0)
2
+ Generator: setuptools (70.2.0)
3
3
  Root-Is-Purelib: true
4
4
  Tag: py3-none-any
5
5
 
reComputer/__init__.py CHANGED
@@ -1 +1 @@
1
- __version__ = "0.1.4"
1
+ __version__ = "0.1.3"
@@ -1,5 +1,5 @@
1
1
  # Jetson-Example: Run Depth Anything on NVIDIA Jetson Orin 🚀
2
- This project provides an one-click deployment of the Depth Anything monocular depth estimation model developed by Hong Kong University and ByteDance. The deployment is visualized on [reComputer](https://www.seeedstudio.com/reComputer-J4012-p-5586.html) (Nvidia Jetson Orin) and includes a WebUI for model conversion to TensorRT and real-time depth estimation.
2
+ This project provides an one-click deployment of the Depth Anything monocular depth estimation model developed by Hong Kong University and ByteDance. The deployment is visualized on [reComputer J4012](https://www.seeedstudio.com/reComputer-J4012-p-5586.html) (Jetson Orin NX 16GB, 100 TOPS) and includes a WebUI for model conversion to TensorRT and real-time depth estimation.
3
3
  <p align="center">
4
4
  <img src="images/WebUI.png" alt="WebUI">
5
5
  </p>
@@ -27,7 +27,7 @@ All models and inference engine implemented in this project are from the officia
27
27
 
28
28
  ## 🥳Getting Started
29
29
  ### 📜Prerequisites
30
- - reComputer J401 [(🛒Buy Here)](https://www.seeedstudio.com/NVIDIAr-Jetson-Orintm-Nano-Developer-Kit-p-5617.html)
30
+ - reComputer J4012 [(🛒Buy Here)](https://www.seeedstudio.com/reComputer-J4012-p-5586.html)
31
31
  - Docker installed on reComputer
32
32
  - USB Camera (optional)
33
33
  ### 🚀Installation
@@ -0,0 +1,67 @@
1
+ # Finetune LLM by Llama-Factory on Jetson
2
+
3
+
4
+ ## Hello
5
+
6
+ 💡 Here's an example of quickly deploying [Llama-Factory](https://github.com/hiyouga/LLaMA-Factory) on Jetson device.
7
+
8
+ 🔥 Hightlights:
9
+ - **Llama-Factory** is an efficient tool to unify efficient Fine-Tuning of 100+ LLMs. 🚀🔍
10
+ - **Jetson-examples** is a toolkit designed to deploy containerized applications on NVIDIA Jetson devices. ✨
11
+ - **Jetson** is powerful AI hardware platform for edge computing.💻
12
+
13
+ 🛠️ Follow the tutorial below to quickly experience the performance of Llama-Factory on edge computing devices.
14
+
15
+ <!-- <div align="center">
16
+ <img alt="yolov10" width="1200px" src="./assets/llama-factory-Jetson.png">
17
+ </div> -->
18
+
19
+ ## Get a Jetson Orin Device 🛒
20
+ | Device Model | Description | Link |
21
+ |--------------|-------------|------|
22
+ | reComputer J4012, powered by Orin NX 16GB, 100 TOPS | Embedded computer powered by Orin NX | [Buy Here](https://www.seeedstudio.com/reComputer-J4012-p-5586.html) |
23
+ | NVIDIA® Jetson AGX Orin™ 64GB Developer Kit | smallest and most powerful AI edge computer | [Buy Here](https://www.seeedstudio.com/NVIDIArJetson-AGX-Orintm-64GB-Developer-Kit-p-5641.html) |
24
+
25
+ ## Getting Started
26
+
27
+ - install **jetson-examples** by pip:
28
+ ```sh
29
+ pip3 install jetson-examples
30
+ ```
31
+ - restart reComputer
32
+ ```sh
33
+ sudo restart
34
+ ```
35
+ - run Llama-Factory webui on jetson in one line:
36
+ ```sh
37
+ reComputer run llama-factory
38
+ ```
39
+ - Please visit http://127.0.0.1:7860
40
+
41
+ <div align="center">
42
+ <img alt="yolov10" width="1200px" src="./assets/webui.png">
43
+ </div>
44
+
45
+
46
+
47
+ ## Run Training Script
48
+
49
+ > **Note:** Some models and datasets require confirmation before using them, so we recommend logging in with your Hugging Face account by:
50
+ > `sudo docker exec -it llama-factory huggingface-cli login`
51
+
52
+ There are a lot of parameters to choose from webui, you can refer to here for more information.
53
+
54
+ For demonstration purposes, set `Model name: Phi-1.5-1.3B`, `Dataset: alpaca_zh`, leave the other parameters unchanged, and then click the `Start` button
55
+
56
+ <div align="center">
57
+ <img alt="yolov10" width="1200px" src="./assets/llama-factory-Jetson.png">
58
+ </div>
59
+
60
+
61
+ ## Build Docker Image
62
+ We highly recommend that you use `jetson-containers` to compile the docker container, as you can see [here](https://github.com/dusty-nv/jetson-containers/pull/566).
63
+
64
+ ## Reference
65
+ - https://github.com/hiyouga/LLaMA-Factory
66
+ - https://github.com/dusty-nv/jetson-containers
67
+
@@ -0,0 +1,4 @@
1
+ #!/bin/bash
2
+
3
+ sudo docker rmi youjiang9977/llama-factory:r35.4.1
4
+ sudo rm -rf /home/$USER/reComputer/jetson-containers/LLaMA-Factory/*
@@ -0,0 +1,52 @@
1
+ #!/bin/bash
2
+
3
+
4
+ # check L4T_VERSION
5
+ # reference https://github.com/dusty-nv/jetson-containers/blob/master/jetson_containers/l4t_version.sh
6
+ ALLOWED_L4T_VERSIONS=("35.3.1" "35.4.1" "35.5.0")
7
+
8
+ ARCH=$(uname -i)
9
+ if [ $ARCH = "aarch64" ]; then
10
+ L4T_VERSION_STRING=$(head -n 1 /etc/nv_tegra_release)
11
+
12
+ if [ -z "$L4T_VERSION_STRING" ]; then
13
+ L4T_VERSION_STRING=$(dpkg-query --showformat='${Version}' --show nvidia-l4t-core)
14
+ L4T_VERSION_ARRAY=(${L4T_VERSION_STRING//./ })
15
+ L4T_RELEASE=${L4T_VERSION_ARRAY[0]}
16
+ L4T_REVISION=${L4T_VERSION_ARRAY[1]}
17
+ else
18
+ L4T_RELEASE=$(echo $L4T_VERSION_STRING | cut -f 2 -d ' ' | grep -Po '(?<=R)[^;]+')
19
+ L4T_REVISION=$(echo $L4T_VERSION_STRING | cut -f 2 -d ',' | grep -Po '(?<=REVISION: )[^;]+')
20
+ fi
21
+
22
+ L4T_REVISION_MAJOR=${L4T_REVISION:0:1}
23
+ L4T_REVISION_MINOR=${L4T_REVISION:2:1}
24
+
25
+ L4T_VERSION="$L4T_RELEASE.$L4T_REVISION"
26
+ echo $L4T_VERSION
27
+ elif [ $ARCH != "x86_64" ]; then
28
+ echo "unsupported architecture: $ARCH"
29
+ exit 1
30
+ fi
31
+
32
+ echo "L4T_VERSION: $L4T_VERSION"
33
+ if [[ ! " ${ALLOWED_L4T_VERSIONS[@]} " =~ " ${L4T_VERSION} " ]]; then
34
+ echo "L4T_VERSION is not in the allowed versions list. Exiting."
35
+ exit 1
36
+ fi
37
+
38
+
39
+ BASE_PATH=/home/$USER/reComputer
40
+ mkdir -p $BASE_PATH/
41
+ JETSON_REPO_PATH="$BASE_PATH/jetson-containers"
42
+ BASE_JETSON_LAB_GIT="https://github.com/dusty-nv/jetson-containers"
43
+ if [ -d $JETSON_REPO_PATH ]; then
44
+ echo "jetson-ai-lab existed."
45
+ else
46
+ echo "jetson-ai-lab does not installed. start init..."
47
+ cd $BASE_PATH/
48
+ git clone --depth=1 $BASE_JETSON_LAB_GIT
49
+ cd $JETSON_REPO_PATH
50
+ bash install.sh
51
+ fi
52
+
@@ -0,0 +1,10 @@
1
+ #!/bin/bash
2
+
3
+
4
+ DATA_PATH="/home/$USER/reComputer/jetson-containers/data"
5
+
6
+ sudo docker run -it --rm --network host --runtime nvidia \
7
+ --volume $DATA_PATH:/data \
8
+ --name llama-factory \
9
+ youjiang9977/llama-factory:r35.4.1
10
+