要素模型"/>
事项要素模型
环境问题
普通Linux环境没什么问题
arm+麒麟系统
- python3.7
- tensorflow==1.14.0(tensorflow-1.14.0-cp37-none-linux_aarch64.whl)
- keras==2.3.0
- h5py==2.10.0(conda install h5py==2.10.0)
- protobuf==3.20.0
docker操作:docker cp xxx 6a8:/root
docker exec -it 6a8 bash
报错
File "/home/qeh/anaconda3/envs/model-system/lib/python3.7/site-packages/keras/engine/saving.py", line 492, in load_wrapperreturn load_function(*args, **kwargs)File "/home/qeh/anaconda3/envs/model-system/lib/python3.7/site-packages/keras/engine/network.py", line 1230, in load_weightsf, self.layers, reshape=reshape)File "/home/qeh/anaconda3/envs/model-system/lib/python3.7/site-packages/keras/engine/saving.py", line 1183, in load_weights_from_hdf5_grouporiginal_keras_version = f.attrs['keras_version'].decode('utf8')
AttributeError: 'str' object has no attribute 'decode'
- h5py版本问题
- pip install h5py==2.10.0
安装h5py时遇到的问题
PackagesNotFoundError: The following packages are not available from current channels:
- h5py==2.10.0
Current channels:
To search for alternate channels that may provide the conda package you’re
looking for, navigate to
and use the search bar at the top of the page.
conda config --append channels conda-forge
conda search h5py==2.10.0
conda install h5py==2.10.0# 不行的话尝试这个
conda install -c conda-forge h5py==2.10.0
安装h5py会遇到各种不可控问题,最好打包conda环境来移植。
conda install conda-pack
# -o 参数指定打包路径和名称
conda pack -n 虚拟环境名 -o 打包环境名.tar.gz
# 创建目录 `my_env`,并将环境解压至该目录
mkdir -p my_env
tar -xzf my_env.tar.gz -C my_env
更多推荐
事项要素模型
发布评论