gpt4 book ai didi

MNIST dataset on Spyder(Spyder上的MNIST数据集)

转载 作者:bug小助手 更新时间:2023-10-25 13:30:56 25 4
gpt4 key购买 nike



I need to install mnist dataset to Spyder (not part of Anaconda), but get the answer that
keras is not found. The Python on Spyder is 3.9.14. How can I do it?

我需要将mnist数据集安装到Spyder(不是Anaconda的一部分),但得到的答案是找不到Keras。Spyder上的巨蟒版本是3.9.14。我该怎么做呢?


I need to install mnist dataset to Spyder (not part of Anaconda), but get the answer that
keras is not found. The Python on Spyder is 3.9.14. How can I do it?

我需要将mnist数据集安装到Spyder(不是Anaconda的一部分),但得到的答案是找不到Keras。Spyder上的巨蟒版本是3.9.14。我该怎么做呢?


import sqlite3
from PIL import Image
import numpy as np
from matplotlib import pyplot
from builtins import dict
from keras.datasets import mnist
(train_X, train_y), (test_X, test_y) = mnist.load_data()

从PIL导入SQlite3导入图像从matplotlib导入NumPy作为NP从matplotlib导入pyploy从内置导入dict从keras导入dict。数据集导入mnist(列车_X,列车_y),(test_X,test_y)=mnist.load_data()


answer:
runfile('/Users/nevendragojlovic/Desktop/Software/eyeye35.5.py', wdir='/Users/nevendragojlovic/Desktop/Software')
Traceback (most recent call last):

回答:runfile(‘/Users/nevendragojlovic/Desktop/Software/eyeye35.5.py’,wdir=‘/Users/nevendragojlovic/Desktop/Software’)回溯(最近一次呼叫):


File /Applications/Spyder.app/Contents/Resources/lib/python3.9/spyder_kernels/py3compat.py:356 in compat_exec
exec(code, globals, locals)

COMPAT_EXEC EXEC中的文件/Applications/Spyder.app/Contents/Resources/lib/python3.9/spyder_kernels/py3compat.py:356(代码、全局变量、本地变量)


File ~/Desktop/Software/eyeye35.5.py:14
from keras.datasets import mnist

来自keras.dataSets导入mnist的文件~/Desktop/Software/yeye35.5.py:14


ModuleNotFoundError: No module named 'keras'

ModuleNotFoundError:No module named 'footer'


更多回答

Just to clarify, libraries are not installed into Spyder. They are installed into the core Python environment, or virtual environment. Is keras installed?

只是为了澄清一下,库并没有安装到Spyder中。它们被安装到核心的Python环境或虚拟环境中。是否安装了Keras?

优秀答案推荐
更多回答

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com