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

本站现有博文324篇,共被浏览808861

本站已经建立2511天!

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