簡體   English   中英

這個張量流消息是什么意思?

[英]What does this tensorflow message mean?

所以這是一個用 ML 制作的數字識別器。所以我收到了這個錯誤,我的程序在發出這個命令后就退出了。 嘗試安裝tensorflow-cpu和通常的 tensorflow ..

我有一個 AMD GPU 和一個 Core i5-10th Gen CPU

2021-11-16 18:53:54.873365: I tensorflow/core/platform/cpu_feature_guard.cc:151] This TensorFlow binary is optimized with oneAPI Deep Neural Network Library (oneDNN) to use the following CPU instructions in performance-critical operations:  AVX AVX2
To enable them in other operations, rebuild TensorFlow with the appropriate compiler flags.

另外我已經保存了模型,這是代碼:

model = tf.keras.models.load_model('handwritten.model')

image_number = 1

while os.path.isfile(f'Image\\Digits{image_number}.png'):
    try:
        img = cv2.imread(f'Image\\Digits{image_number}.png')[:,:,0]
        img = np.invert(np.array([img]))
        prediction = model.predict(img)
        speak(f"This Digit is Probably a {np.argmax(prediction)}")
        plt.imshow(img[0], cmap=plt.cm.binary)

    except:
        speak("Error!")

    finally:
        image_number += 1 

Tensorflow 僅與 Nvidia GPU 兼容(使用 Cuda 語言)。 關於消息,它只是一個警告,告訴您可以通過使用適當的標志從源代碼編譯它來更好地優化 CPU 上的 Tensorflow,以便考慮 CPU 的 AVX AVX2 指令集。 話雖如此,出於計算時間的原因,您只能訓練簡單的模型。

暫無
暫無

聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.

 
粵ICP備18138465號  © 2020-2024 STACKOOM.COM