EADST

ONNX Set Device ID with CUDA

ONNX Set the Device ID with CUDA

import onnxruntime as ort

model_path = ''

providers = [
    ('CUDAExecutionProvider', {
        'device_id': 0,
        'arena_extend_strategy': 'kNextPowerOfTwo',
        'gpu_mem_limit': 2 * 1024 * 1024 * 1024,
        'cudnn_conv_algo_search': 'EXHAUSTIVE',
        'do_copy_in_default_stream': True,
    }),
    'CPUExecutionProvider',
]

session = ort.InferenceSession(model_path, providers=providers)

Reference:

CUDA Execution Provider

相关标签
About Me
XD
Goals determine what you are going to be.
Category
标签云
NLP Use Python Tracking Qwen2 git-lfs diffusers Conda TensorFlow Cloudreve LLM Dataset Gemma Hilton Docker 第一性原理 BF16 Rebuttal Miniforge Domain Vim Web Quantization Git Augmentation v0.dev Paper Linux 版权 FP8 LeetCode VGG-16 PIP OpenCV 继承 BeautifulSoup C++ Safetensors RL ONNX HaggingFace SVR Template Search BTC Heatmap 图标 TTS TensorRT News CUDA GGML PyCharm Password UI Shortcut SQLite GPTQ SPIE Tensor HuggingFace Windows Nginx 净利润 ms-swift Streamlit Numpy 算法题 Color Excel 腾讯云 Food FP64 OCR 多进程 VSCode CV 搞笑 API PyTorch git hf Bin uWSGI QWEN FP16 XGBoost Pickle Data Video Logo 论文 Jupyter Michelin DeepStream Pandas CEIR 顶会 AI CTC JSON 证件照 多线程 Bitcoin ResNet-50 Firewall Pillow FlashAttention printf Breakpoint Claude tar mmap Plate Image2Text RGB SAM LLAMA Jetson Mixtral Quantize PDB Vmess Card 域名 InvalidArgumentError Llama Disk Hotel YOLO Ptyhon 云服务器 DeepSeek ChatGPT CSV Bipartite OpenAI Paddle RAR Django Qwen2.5 Markdown Base64 scipy Bert Datetime NameSilo 阿里云 ModelScope GoogLeNet PDF Clash TSV Crawler COCO Anaconda CLAP transformers 论文速读 Magnet Zip CC Github icon Distillation Plotly Freesound 音频 CAM FP32 Pytorch GPT4 IndexTTS2 v2ray Hungarian Animate Knowledge Statistics Random Permission 关于博主 WebCrawler LoRA Sklearn 财报 GIT Interview UNIX WAN Proxy logger llama.cpp torchinfo VPN Review Diagram Agent Ubuntu 报税 Transformers 强化学习 Translation 飞书 Algorithm Website LaTeX Math 递归学习法 FastAPI MD5 uwsgi 签证 tqdm Google SQL NLTK XML Land EXCEL Input 图形思考法 Qwen Baidu 公式 Tiktoken Attention
站点统计

本站现有博文334篇,共被浏览935914

本站已经建立2646天!

热门文章
文章归档
回到顶部