[Python] Is there any way to know if these are real weights?

Discussão em 'Python' iniciado por Stack, Março 30, 2025.

  1. Stack

    Stack Membro Participativo

    I am using this repository: https://github.com/Chang-Chia-Chi/TrackNet-Badminton-Tracking-tensorflow2. I am new to this field, please dont judge me heavily. I want to run the model with the weights that is give in the repository, but i dont know if these are real weights trained by them. Also this error pops up when i run the predict.py code in the repository after cloning:

    PS C:\Users\georg\OneDrive\Documents\PRAJJ\TrackNet-Badminton-Tracking-tensorflow2> python predict.py
    2025-03-30 12:37:07.788180: I tensorflow/core/platform/cpu_feature_guard.cc:193] This TensorFlow binary is optimized with oneAPI Deep Neural Network Library (oneDNN) to use the following CPU instructions in performance-critical operations: AVX2
    To enable them in other operations, rebuild TensorFlow with the appropriate compiler flags.
    2025-03-30 12:37:07.792615: I tensorflow/core/common_runtime/process_util.cc:146] Creating new thread pool with default inter op setting: 2. Tune using inter_op_parallelism_threads for best performance.
    Load weights successfully
    Load csv file successfully
    Beginning predicting......
    1/1 [==============================] - 5s 5s/step
    Traceback (most recent call last):
    File "C:\Users\georg\OneDrive\Documents\PRAJJ\TrackNet-Badminton-Tracking-tensorflow2\predict.py", line 137, in <module>
    _, cnts, _ = cv2.findContours(h_pred[0].copy(), cv2.RETR_EXTERNAL, cv2.CHAIN_APPROX_SIMPLE)
    ValueError: not enough values to unpack (expected 3, got 2)
    WARNING:tensorflow:Detecting that an object or model or tf.train.Checkpoint is being deleted with unrestored values. See the following logs for the specific values in question. To silence these warnings, use status.expect_partial(). See https://www.tensorflow.org/api_docs/python/tf/train/Checkpoint#restorefor details about the status object returned by the restore function.
    WARNING:tensorflow:Value in checkpoint could not be found in the restored object: (root).optimizer.decay
    WARNING:tensorflow:Value in checkpoint could not be found in the restored object: (root).optimizer.learning_rate
    WARNING:tensorflow:Value in checkpoint could not be found in the restored object: (root).optimizer.rho
    WARNING:tensorflow:Value in checkpoint could not be found in the restored object: (root).optimizer.iter
    WARNING:tensorflow:Value in checkpoint could not be found in the restored object: (root).optimizer's state 'accum_grad' for (root).conv_t1.bn_1.gamma
    WARNING:tensorflow:Value in checkpoint could not be found in the restored object: (root).optimizer's state 'accum_grad' for (root).conv_t1.bn_1.beta
    WARNING:tensorflow:Value in checkpoint could not be found in the restored object: (root).optimizer's state 'accum_grad' for (root).conv_t1.conv_1.kernel
    WARNING:tensorflow:Value in checkpoint could not be found in the restored object: (root).optimizer's state 'accum_grad' for (root).conv_t1.conv_1.bias

    Continue reading...

Compartilhe esta Página