mirror of
https://github.com/azaion/annotations.git
synced 2026-04-23 01:46:31 +00:00
import Tensorrt not in compile time in order to dynamically load tensorrt only if nvidia gpu is present
This commit is contained in:
@@ -14,11 +14,11 @@ cdef class OnnxEngine(InferenceEngine):
|
||||
model_meta = self.session.get_modelmeta()
|
||||
print("Metadata:", model_meta.custom_metadata_map)
|
||||
|
||||
cdef tuple get_input_shape(self):
|
||||
cpdef tuple get_input_shape(self):
|
||||
shape = self.input_shape
|
||||
return shape[2], shape[3]
|
||||
|
||||
cdef int get_batch_size(self):
|
||||
cpdef int get_batch_size(self):
|
||||
return self.batch_size
|
||||
|
||||
cpdef run(self, input_data):
|
||||
|
||||
Reference in New Issue
Block a user