Replies: 1 comment
-
Python3.10, Ubuntu 22 - has the same problem |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
Don`t work.
Traceback (most recent call last):
File "C:\Users\andre\AppData\Local\Programs\Python\Python312\Lib\tkinter_init_.py", line 1948, in call
return self.func(*args)
^^^^^^^^^^^^^^^^
File "C:\Users\andre\AppData\Local\Programs\Python\Python312\Lib\site-packages\customtkinter\windows\widgets\ctk_button.py", line 554, in _clicked
self._command()
File "C:\Users\andre\Deep-Live-Cam-main\Deep-Live-Cam-main\modules\ui.py", line 95, in
start_button = ctk.CTkButton(root, text='Start', cursor='hand2', command=lambda: select_output_path(start))
^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\andre\Deep-Live-Cam-main\Deep-Live-Cam-main\modules\ui.py", line 192, in select_output_path
start()
File "C:\Users\andre\Deep-Live-Cam-main\Deep-Live-Cam-main\modules\core.py", line 177, in start
if predict_image(modules.globals.target_path):
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\andre\Deep-Live-Cam-main\Deep-Live-Cam-main\modules\predicter.py", line 20, in predict_image
return opennsfw2.predict_image(target_path) > MAX_PROBABILITY
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\andre\AppData\Local\Programs\Python\Python312\Lib\site-packages\opennsfw2_inference.py", line 33, in predict_image
model = make_open_nsfw_model(weights_path=weights_path)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\andre\AppData\Local\Programs\Python\Python312\Lib\site-packages\opennsfw2_model.py", line 138, in make_open_nsfw_model
x = tf.pad(x, [[0, 0], [3, 3], [3, 3], [0, 0]], "CONSTANT")
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\andre\AppData\Local\Programs\Python\Python312\Lib\site-packages\tensorflow\python\util\traceback_utils.py", line 153, in error_handler
raise e.with_traceback(filtered_tb) from None
File "C:\Users\andre\AppData\Local\Programs\Python\Python312\Lib\site-packages\keras\src\backend\common\keras_tensor.py", line 91, in tf_tensor
raise ValueError(
ValueError: A KerasTensor cannot be used as input to a TensorFlow function. A KerasTensor is a symbolic placeholder for a shape and dtype, used when constructing Keras Functional models or Keras Functions. You can only use it as input to a Keras layer or a Keras operation (from the namespaces
keras.layers
andkeras.operations
). You are likely doing something like:What you should do instead is wrap
tf_fn
in a layer:Beta Was this translation helpful? Give feedback.
All reactions