Skip to content

Algorithms selected propblem while use int8 precision #778

@XiaoyuWang199

Description

@XiaoyuWang199

Description

Algorithms selected propblem while use int8 precision。 TensorRT 7.1 add a new function to choose the algorithm manually.
it works well in fp32 percision because algorithms are choosed for inference. while in calibration progress, choose algorithms will
occur problems .
[TRT][Debug]Builder timing cache: created 0 entries, 0 hit(s)
[TRT][ERROR]../builder/tacticOptimizer.cpp (1577) - Assertion Error in computeCosts: 0 ((strictTypeConstraints || nbAlgoChoices > 0) && "Number of Algorithm choices for a node must not be zero, unless strictTypeConstraints is true.")

same problem will happen in official sample when I add the choose algorithms function(copy from sampleAlgorithmselector) to sampleINT8. and disable readcache while excuse calibration to allow choosing algorithm during the calibration progress.

图片

we can found the algorithms nbchoices for caliration is much less for inference nbchoices for the same layer. (both for conv0+relu0 layer, before calibration algorithm has only 1 choose while after calibration has 34 choices )
图片

图片
and may occur the bug.

and for conv1/dw it seems have 0 choices and throws an error, but it seems that algorithms caskconvolution Tactic 182513... is worked, and why it shows "Number of Algorithm choices for a node must not be zero, unless strictTypeConstraints is true.
图片

[TRT][Debug]Builder timing cache: created 0 entries, 0 hit(s)
[TRT][ERROR]../builder/tacticOptimizer.cpp (1577) - Assertion Error in computeCosts: 0 ((strictTypeConstraints || nbAlgoChoices > 0) && "Number of Algorithm choices for a node must not be zero, unless strictTypeConstraints is true.")

Environment

TensorRT Version: TensorRT v7.1.3
GPU Type: NVIDIA TESLA P4000
CUDA Version: cuda10.2
CUDNN Version: 8.0

Baremetal or Container (which commit + image + tag):
图片

Relevant Files

Steps To Reproduce

Metadata

Metadata

Assignees

No one assigned

    Labels

    triagedIssue has been triaged by maintainers

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions