Run this model with HF Jobs
Run litert-community/PiVo-1.4M on Hugging Face's managed compute, monitor its progress, and retrieve the results when it's done.
Paste one of these prompts into your coding agent:
Fine-tune on my dataset
Use HF Jobs to fine-tune https://huggingface.co/litert-community/PiVo-1.4M. Ask me which dataset to train on, then push the fine-tuned model to a new model repo. Run `hf jobs --help` first to learn the CLI.
Run batch inference
Use HF Jobs to run batch inference with https://huggingface.co/litert-community/PiVo-1.4M on the inputs in a mounted HF Bucket. Ask me which Bucket to use, then write the outputs back to it and keep each input ID. Run `hf jobs --help` first to learn the CLI.
Instructions to use litert-community/PiVo-1.4M with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- LiteRT
How to use litert-community/PiVo-1.4M with LiteRT:
# No code snippets available yet for this library. # To use this model, check the repository files and the library's documentation. # Want to help? PRs adding snippets are welcome at: # https://github.com/huggingface/huggingface.js
- Notebooks
- Google Colab
- Kaggle
Download runner/fetch_kit.sh from litert-community/PiVo-1.4M: direct link, hf CLI and curl.
- Browser
- Download file 4.96 kB
-
https://huggingface.co/litert-community/PiVo-1.4M/resolve/main/runner/fetch_kit.sh
- Command line
-
hf download hf://litert-community/PiVo-1.4M/runner/fetch_kit.sh
-
curl -L -o fetch_kit.sh https://huggingface.co/litert-community/PiVo-1.4M/resolve/main/runner/fetch_kit.sh
4.96 kB
| # fetch_kit.sh: the LiteRT 2.3.0 headers and libraries pivo_runner builds against and runs with, into runner/kit/. | |
| # bash runner/fetch_kit.sh (from anywhere; downloads about 27 MB once, then checks the files) | |
| # Every download is checked against the SHA-256 below (the files this repository's runs used): | |
| # kit/litert_cc_sdk/ the LiteRT C API headers (GitHub release v2.3.0, litert_cc_sdk.zip) | |
| # kit/android/libLiteRt.so Maven com.google.ai.edge.litert:litert:2.3.0 (jni/arm64-v8a) | |
| # kit/android/libLiteRtClGlAccelerator.so Maven litert-gpu:2.3.0 (the GPU accelerator) | |
| # kit/android/libLiteRtDispatch_Qualcomm.so, libLiteRtCompilerPlugin_Qualcomm.so | |
| # Maven litert-npu-runtime-qualcomm:2.3.0 | |
| # kit/android_gt/*.so Maven litert-npu-runtime-google-tensor:2.3.0 | |
| # kit/mac/libLiteRt.dylib, libLiteRtMetalAccelerator.dylib | |
| # the ai-edge-litert 2.3.0 wheel for macOS arm64 (PyPI) | |
| # The Qualcomm NPU also needs Qualcomm's QAIRT 2.50.0.260828 libraries on the phone (Qualcomm's SDK under Qualcomm's | |
| # license, not downloaded here): runner/README.md lists the files and their SHA-256. | |
| set -euo pipefail | |
| R=$(cd "$(dirname "$0")" && pwd) | |
| O=$R/kit | |
| MAVEN=https://dl.google.com/android/maven2/com/google/ai/edge/litert | |
| sha() { shasum -a 256 "$1" | cut -d' ' -f1; } | |
| fetch() { # url file sha256: download once, then check | |
| if [ ! -f "$2" ]; then curl -fsSL -o "$2.part" "$1"; mv "$2.part" "$2"; fi | |
| local got; got=$(sha "$2") | |
| if [ "$got" != "$3" ]; then echo "$2: sha256 $got, expected $3" >&2; exit 1; fi | |
| echo "fetched $(basename "$2") $(stat -f %z "$2" 2>/dev/null || stat -c %s "$2") B" | |
| } | |
| mkdir -p "$O/dl" "$O/android" "$O/android_gt" "$O/mac" | |
| fetch https://github.com/google-ai-edge/LiteRT/releases/download/v2.3.0/litert_cc_sdk.zip "$O/dl/litert_cc_sdk.zip" \ | |
| 44ebb188ae1a510f233639fa499928fdaaba46436a153a2dbfbb9d87d59728d2 | |
| fetch "$MAVEN/litert/2.3.0/litert-2.3.0.aar" "$O/dl/litert-2.3.0.aar" \ | |
| 9508c6e9142646f0f2bc1fe68b3925fb470ee7ddd29114540339a04a8ab189dc | |
| fetch "$MAVEN/litert-gpu/2.3.0/litert-gpu-2.3.0.aar" "$O/dl/litert-gpu-2.3.0.aar" \ | |
| 173a4c3813601f7e9542f4e6a49e237775e2f9ce1e0948f35407098bffb1824f | |
| fetch "$MAVEN/litert-npu-runtime-qualcomm/2.3.0/litert-npu-runtime-qualcomm-2.3.0.aar" \ | |
| "$O/dl/litert-npu-runtime-qualcomm-2.3.0.aar" 55aa22e89b7decb9e2f56548188b9e8c42cc8f7a828e2ec4a17715079b313679 | |
| fetch "$MAVEN/litert-npu-runtime-google-tensor/2.3.0/litert-npu-runtime-google-tensor-2.3.0.aar" \ | |
| "$O/dl/litert-npu-runtime-google-tensor-2.3.0.aar" 5f38ab3de4b99ef75edf13c595cf0c090b10a82d9697f5b55703409757e786f7 | |
| WHL=ai_edge_litert-2.3.0-cp312-cp312-macosx_12_0_arm64.whl | |
| fetch "https://files.pythonhosted.org/packages/6f/12/86fe17e7069ae792c6e21c523151b34fc03b29a886340e760feaf40237dc/$WHL" \ | |
| "$O/dl/$WHL" 2cd92f02fc9616755670027c5b020bfee5c72ae50cf5d33e92465a863b705a8b | |
| rm -rf "$O/litert_cc_sdk" | |
| unzip -q "$O/dl/litert_cc_sdk.zip" 'litert_cc_sdk/litert/c/*' 'litert_cc_sdk/litert/build_common/*' -d "$O" | |
| # build_config.h is generated from build_config.h.in by CMake in the SDK's own build; every toggle 0 = GPU and NPU on | |
| sed -E 's/^#cmakedefine01 ([A-Z_0-9]+)/#define \1 0/' "$O/litert_cc_sdk/litert/build_common/build_config.h.in" \ | |
| > "$O/litert_cc_sdk/litert/build_common/build_config.h" | |
| unzip -q -o -j "$O/dl/litert-2.3.0.aar" jni/arm64-v8a/libLiteRt.so -d "$O/android" | |
| unzip -q -o -j "$O/dl/litert-gpu-2.3.0.aar" jni/arm64-v8a/libLiteRtClGlAccelerator.so -d "$O/android" | |
| unzip -q -o -j "$O/dl/litert-npu-runtime-qualcomm-2.3.0.aar" 'jni/arm64-v8a/*.so' -d "$O/android" | |
| unzip -q -o -j "$O/dl/litert-npu-runtime-google-tensor-2.3.0.aar" 'jni/arm64-v8a/*.so' -d "$O/android_gt" | |
| unzip -q -o -j "$O/dl/$WHL" ai_edge_litert/libLiteRt.dylib ai_edge_litert/libLiteRtMetalAccelerator.dylib -d "$O/mac" | |
| check() { # file sha256 | |
| [ "$(sha "$1")" = "$2" ] || { echo "$1: sha256 differs from the one this repository's runs used" >&2; exit 1; } | |
| } | |
| check "$O/android/libLiteRt.so" e5b7e3413a8b428b1a1b669f368cf613058868bc7b63e10d0b9c2e6ba55c97d8 | |
| check "$O/android/libLiteRtClGlAccelerator.so" c200369269a3994b646a8d0ac56ff29127c6ce742abcfd345a7d478eab3b6c6d | |
| check "$O/android/libLiteRtCompilerPlugin_Qualcomm.so" 51cff612134bc5d0e3b56db9c285f734218ae984f7201569d067b9e86b2b5ae2 | |
| check "$O/android/libLiteRtDispatch_Qualcomm.so" 22e2d581555617c4a4dabc46ed74833829816e9cd13a0eea27dd4d2178049751 | |
| check "$O/android_gt/libLiteRtCompilerPlugin_google_tensor.so" \ | |
| 6b1432e771c54b970412cd0a2450611a465011df7e3314321d813615f47c244e | |
| check "$O/android_gt/libLiteRtDispatch_GoogleTensor.so" e38144002de11a15f653bb34f1c7efa4cb5af7acdddca424eb32297c5b5f9391 | |
| check "$O/mac/libLiteRt.dylib" f3d8b2c3dea5125111de6b005820088629efd13db04b5f157ffd4f2c5dbb318b | |
| check "$O/mac/libLiteRtMetalAccelerator.dylib" 5531feca4ff0e2c67628e09d635a6f79da74534e88b7a3d262efa5dcda59e95d | |
| echo KIT_DONE | |