Skip to content

Latest commit

 

History

History
33 lines (26 loc) · 1.26 KB

File metadata and controls

33 lines (26 loc) · 1.26 KB

Feature Extraction Examples

This directory contains a script that showcases how to use text embedding models as feature extractors for text embeddings on HPUs.

Single-HPU inference

PT_HPU_LAZY_MODE=1 python run_feature_extraction.py \
    --model_name_or_path Supabase/gte-small \
    --source_sentence "What is a deep learning architecture for feature extraction?" \
    --input_texts "There are many different variants of apples created every year." \
        "BERT is a common machine learning architecture for text-based applications." \
        "Alexander Hamilton is one of the founding fathers of the United States." \
    --use_hpu_graphs \
    --sdp_on_bf16 \
    --bf16