• tensorrt中builder.max_workspace_size的作用


    首先单位是字节,比如 builder.max_workspace_size = 1<< 30 就是 2^30 bytes 即 1 GB。

    它的作用是给出模型中任一层能使用的内存上限。运行时,每一层需要多少内存系统分配多少,并不是每次都分 1 GB,但不会超过 1 GB。

    One particularly important property is the maximum workspace size.

    • Layer algorithms often require temporary workspace. This parameter limits the maximum size that any layer in the network can use. If an insufficient scratch is provided, it is possible that TensorRT may not be able to find an implementation for a given layer.

    一个特别重要的特性是最大工作空间大小。
    层算法通常需要临时工作空间。 此参数限制网络中任何层可以使用的最大大小。 如果提供的暂存不足,TensorRT 可能无法找到给定层的实现。

    参考:

    https://forums.developer.nvidia.com/t/the-significance-of-builder-max-workspace-size/72364/2

    https://docs.nvidia.com/deeplearning/tensorrt/developer-guide/index.html#build_engine_c

  • 相关阅读:
    获取平台所有接口的IP和MAC地址
    共享内存
    消息队列
    shell常见语法
    保存结构体到文件
    Bookmarks
    js打开新窗口
    要买的书
    批量下载辅助工具
    解决word没有菜单栏和工具栏
  • 原文地址:https://www.cnblogs.com/mrlonely2018/p/14841562.html
Copyright © 2020-2023  润新知