File tree Expand file tree Collapse file tree 1 file changed +10
-1
lines changed Expand file tree Collapse file tree 1 file changed +10
-1
lines changed Original file line number Diff line number Diff line change 1- // Copyright 2019-2022 , NVIDIA CORPORATION & AFFILIATES. All rights reserved.
1+ // Copyright 2019-2023 , NVIDIA CORPORATION & AFFILIATES. All rights reserved.
22//
33// Redistribution and use in source and binary forms, with or without
44// modification, are permitted provided that the following conditions
@@ -741,6 +741,15 @@ ModelInstanceState::ValidateTypedSequenceControl(
741741 }
742742 }
743743
744+ // check if the data type is supported by PyTorch
745+ if (!ModelConfigDataTypeToTorchType (tensor_datatype).first ) {
746+ return TRITONSERVER_ErrorNew (
747+ TRITONSERVER_ERROR_INTERNAL,
748+ (" input '" + tensor_name + " ' type '" + tensor_datatype +
749+ " ' is not supported by PyTorch." )
750+ .c_str ());
751+ }
752+
744753 ip_index = std::atoi (tensor_name.substr (start_pos + 2 ).c_str ());
745754 input_index_map_[tensor_name] = ip_index;
746755 }
You can’t perform that action at this time.
0 commit comments