mirror of
https://github.com/modelscope/modelscope.git
synced 2025-12-16 08:17:45 +01:00
fix undefined name tf, while execute tf.stack (#1294)
This commit is contained in:
@@ -206,6 +206,7 @@ class OCRDetectionPipeline(Pipeline):
|
||||
img_pad_resize = img_pad_resize - np.array(
|
||||
[123.68, 116.78, 103.94], dtype=np.float32)
|
||||
|
||||
import tensorflow as tf
|
||||
with self._graph.as_default():
|
||||
resize_size = tf.stack([resize_size, resize_size])
|
||||
orig_size = tf.stack([max(h, w), max(h, w)])
|
||||
|
||||
Reference in New Issue
Block a user