Lines Matching refs:NN_VALIDATE
66 #define NN_VALIDATE(condition) \ macro
289 NN_VALIDATE(timing.timeOnDevice.value() <= timing.timeInDriver.value()) << lazyMessage(); in validateTiming()
342 NN_VALIDATE(isValidExtensionName(extension.name)); in validateExtension()
354 NN_VALIDATE(iter == types.end()) << "Extension has duplicate type " << *iter; in validateExtension()
372 NN_VALIDATE(nameIter == names.end()) in validateExtensions()
395 NN_VALIDATE(location.pointer == kNullptrVariant) in validateOperandDataLocation()
417 NN_VALIDATE(location.pointer == kNullptrVariant) in validateOperandDataLocation()
428 NN_VALIDATE(location.pointer == kNullptrVariant) << "SUBGRAPH with a non-null pointer"; in validateOperandDataLocation()
444 NN_VALIDATE(nonNull) << "POINTER with a null pointer"; in validateOperandDataLocation()
464 NN_VALIDATE(operand.dimensions.empty()) in validateOperandDimensions()
481 NN_VALIDATE(!operand.dimensions.empty()) in validateOperandDimensions()
485 NN_VALIDATE(size.has_value()) << "Tensor dimensions overflow"; in validateOperandDimensions()
566 NN_VALIDATE(operand.zeroPoint >= 0 && operand.zeroPoint <= 255) in validateOperandZeroPoint()
571 NN_VALIDATE(operand.zeroPoint >= -128 && operand.zeroPoint <= 127) in validateOperandZeroPoint()
576 NN_VALIDATE(operand.zeroPoint >= 0 && operand.zeroPoint <= 65535) in validateOperandZeroPoint()
615 NN_VALIDATE(std::holds_alternative<Operand::NoParams>(operand.extraParams)) in validateOperandExtraParams()
620 NN_VALIDATE( in validateOperandExtraParams()
653 NN_VALIDATE(std::holds_alternative<Operand::NoParams>(operand.extraParams) || in validateOperandExtraParams()
732 NN_VALIDATE(std::all_of(handle.fds.begin(), handle.fds.end(), in validateHandle()
738 NN_VALIDATE(handle != nullptr); in validateSharedHandle()
743 NN_VALIDATE(memory.fd.ok()); in validateMemory()
749 NN_VALIDATE(memory.fd.ok()); in validateMemory()
761 NN_VALIDATE(memory.handle.get() != nullptr); in validateMemory()
771 NN_VALIDATE(memory != nullptr); in validateSharedMemory()
792 NN_VALIDATE(iter == sortedIndexes.end()) in validateModelSubgraphInputOutputs()
800 NN_VALIDATE(containsIndex(i)) in validateModelSubgraphInputOutputs()
830 NN_VALIDATE(operandValueKnown[k]) << "Operation " << i << " input " << j << " (operand " in validateExecutionOrder()
839 NN_VALIDATE(!operandValueKnown[k]) << "Operation " << i << " output " << j in validateExecutionOrder()
847 NN_VALIDATE(operandValueKnown[i]) << "Operand " << i << " is never written"; in validateExecutionOrder()
878 NN_VALIDATE(!subgraph.operands.empty()); in validateModelSubgraph()
879 NN_VALIDATE(!subgraph.operations.empty()); in validateModelSubgraph()
911 NN_VALIDATE(isValidExtensionName(extensionNameAndPrefix.name)); in validateModelExtensionNamesAndPrefixes()
924 NN_VALIDATE(nameIter == names.end()) in validateModelExtensionNamesAndPrefixes()
936 NN_VALIDATE(typeIter == types.end()) in validateModelExtensionNamesAndPrefixes()
970 NN_VALIDATE((*path)[subgraphIndex] == false) << "Model contains a circular subgraph reference"; in checkNoReferenceCycles()
1054 NN_VALIDATE(location.pointer == kNullptrVariant); in validateRequestArgument()
1068 NN_VALIDATE(location.pointer == kNullptrVariant); in validateRequestArgument()
1073 NN_VALIDATE(dimensions.empty()); in validateRequestArgument()
1078 NN_VALIDATE(!isNullptr); in validateRequestArgument()
1083 NN_VALIDATE(std::holds_alternative<void*>(location.pointer)); in validateRequestArgument()
1093 NN_VALIDATE(std::get<Request::MemoryDomainToken>(memoryPool) != kInvalidMemoryDomainToken); in validateRequestMemoryPool()
1097 NN_VALIDATE(std::get<SharedBuffer>(memoryPool) != nullptr); in validateRequestMemoryPool()
1195 NN_VALIDATE(isOutput) in validateRequestArgumentsForModel()
1198 NN_VALIDATE(allowUnspecifiedOutput) in validateRequestArgumentsForModel()
1207 NN_VALIDATE(isOutput && allowUnspecifiedOutput) in validateRequestArgumentsForModel()
1215 NN_VALIDATE(modelRank == 0 || requestRank == modelRank) in validateRequestArgumentsForModel()
1220 NN_VALIDATE(modelRank == 0 || operand.dimensions[i] == 0 || in validateRequestArgumentsForModel()
1226 NN_VALIDATE(isOutput && allowUnspecifiedOutput) in validateRequestArgumentsForModel()
1272 NN_VALIDATE(!preparedModels.empty()); in validateMemoryDescImpl()
1273 NN_VALIDATE(!inputRoles.empty() || !outputRoles.empty()); in validateMemoryDescImpl()
1281 NN_VALIDATE(preparedModel != nullptr); in validateMemoryDescImpl()
1283 NN_VALIDATE(model != nullptr); in validateMemoryDescImpl()
1289 NN_VALIDATE(success); in validateMemoryDescImpl()
1295 NN_VALIDATE(preparedModel != nullptr); in validateMemoryDescImpl()
1297 NN_VALIDATE(model != nullptr); in validateMemoryDescImpl()
1303 NN_VALIDATE(success); in validateMemoryDescImpl()
1325 NN_VALIDATE(!isNonExtensionScalar(opType) || dimensions.empty()) in validateMemoryDescImpl()
1430 NN_VALIDATE(!channelQuant.scales.empty()) << tag; in validateOperandSymmPerChannelQuantParamsImpl()
1441 NN_VALIDATE(type.dimensions.empty()) << tag << " invalid dimensions for scalar type"; in validateScalarDimensions()
1446 NN_VALIDATE(0 <= type.zeroPoint && type.zeroPoint <= 255) in validateQuant8AsymmParams()
1453 NN_VALIDATE(-128 <= type.zeroPoint && type.zeroPoint <= 127) in validateQuant8AsymmSignedParams()
1466 NN_VALIDATE(0 <= type.zeroPoint && type.zeroPoint <= 65535) in validateQuant16AsymmParams()
1488 NN_VALIDATE(!type.dimensions.empty()) << tag << " invalid operand dimensions"; in validateTensorDimensions()
1510 NN_VALIDATE(extensionOperandTypeInfo != nullptr); in validateOperandTypeImpl()
1519 NN_VALIDATE(extensionOperandTypeInfo == nullptr); in validateOperandTypeImpl()
1816 NN_VALIDATE(inputIndexes.size() == 2 && outputIndexes.size() == 1) in validateOperationButNotOperandsImpl()
1850 NN_VALIDATE((inputIndexes.size() == 3 || inputIndexes.size() == 2) && in validateOperationButNotOperandsImpl()
1889 NN_VALIDATE((inputIndexes.size() == 3 || inputIndexes.size() == 2) && in validateOperationButNotOperandsImpl()
1928 NN_VALIDATE(inputIndexes.size() == 2 && outputIndexes.size() == 1) in validateOperationButNotOperandsImpl()
1931 NN_VALIDATE(inputType == OperandType::TENSOR_FLOAT16 || in validateOperationButNotOperandsImpl()
1954 NN_VALIDATE(inputIndexes.size() == 3 && outputIndexes.size() == 2) in validateOperationButNotOperandsImpl()
1957 NN_VALIDATE(inputType == OperandType::TENSOR_FLOAT32 || in validateOperationButNotOperandsImpl()
1970 NN_VALIDATE(inputIndexes.size() == 4 && outputIndexes.size() == 1) in validateOperationButNotOperandsImpl()
1973 NN_VALIDATE(inputType == OperandType::TENSOR_FLOAT16 || in validateOperationButNotOperandsImpl()
2010 NN_VALIDATE(inputIndexes.size() == 61 && in validateOperationButNotOperandsImpl()
2021 NN_VALIDATE(inputType == OperandType::TENSOR_FLOAT32 || in validateOperationButNotOperandsImpl()
2053 NN_VALIDATE((inputIndexes.size() == 23 || inputIndexes.size() == 27) && in validateOperationButNotOperandsImpl()
2061 NN_VALIDATE(inputType == OperandType::TENSOR_FLOAT32 || in validateOperationButNotOperandsImpl()
2094 NN_VALIDATE(inputIndexes.size() == 15 && outputIndexes.size() == 2) in validateOperationButNotOperandsImpl()
2112 NN_VALIDATE(inputIndexes.size() == 3 && outputIndexes.size() == 1) in validateOperationButNotOperandsImpl()
2128 NN_VALIDATE(inputIndexes.size() == 6 && outputIndexes.size() == 2) in validateOperationButNotOperandsImpl()
2164 NN_VALIDATE(inputIndexes.size() == 7 && outputIndexes.size() == 2) in validateOperationButNotOperandsImpl()
2185 NN_VALIDATE((inputIndexes.size() == 3 || inputIndexes.size() == 2) && in validateOperationButNotOperandsImpl()
2234 NN_VALIDATE((inputIndexes.size() == 4 || inputIndexes.size() == 3) && in validateOperationButNotOperandsImpl()
2290 NN_VALIDATE(inputIndexes.size() == 2 && outputIndexes.size() == 1) in validateOperationButNotOperandsImpl()
2337 NN_VALIDATE(inputIndexes.size() == 3 && outputIndexes.size() == 1) in validateOperationButNotOperandsImpl()
2383 NN_VALIDATE(inputIndexes.size() == 1 && outputIndexes.size() == 1) in validateOperationButNotOperandsImpl()
2422 NN_VALIDATE(inputOperand.dimensions.empty() || outputOperand.dimensions.empty() || in validateOperationButNotOperandsImpl()
2430 NN_VALIDATE(inputIndexes.size() == 3 && outputIndexes.size() == 1) in validateOperationButNotOperandsImpl()
2456 NN_VALIDATE(inputIndexes.size() == 2 && outputIndexes.size() == 1) in validateOperationButNotOperandsImpl()
2476 NN_VALIDATE(inputIndexes.size() == 2 && outputIndexes.size() == 1) in validateOperationButNotOperandsImpl()
2506 NN_VALIDATE(inputType == OperandType::TENSOR_FLOAT16 || in validateOperationButNotOperandsImpl()
2527 NN_VALIDATE(inputIndexes.size() == 2 && outputIndexes.size() == 1) in validateOperationButNotOperandsImpl()
2553 NN_VALIDATE((inputIndexes.size() == 12 || inputIndexes.size() == 9) && in validateOperationButNotOperandsImpl()
2576 NN_VALIDATE(filterType == inputType || in validateOperationButNotOperandsImpl()
2580 NN_VALIDATE(filterType != OperandType::TENSOR_QUANT8_SYMM_PER_CHANNEL || in validateOperationButNotOperandsImpl()
2612 NN_VALIDATE(inputIndexes.size() == 2 && outputIndexes.size() == 1) in validateOperationButNotOperandsImpl()
2638 NN_VALIDATE(inputIndexes.size() == 2 && outputIndexes.size() == 1) in validateOperationButNotOperandsImpl()
2671 NN_VALIDATE(operationRegistration != nullptr) << opType << " not registered"; in validateOperationButNotOperandsImpl()
2673 NN_VALIDATE(operationRegistration->validate != nullptr) in validateOperationButNotOperandsImpl()