我在使用conda install -c conda-forge opencv命令安装opencv后遇到了这个问题
import cv2
这是我得到的错误
---------------------------------------------------------------------------
ImportError Traceback (most recent call last)
<ipython-input-155-864860d2a115> in <module>
----> 1 import cv2
2
ImportError: dlopen(/Users/name/anaconda3/envs/myenv/lib/python3.6/site-packages/cv2.cpython-36m-darwin.so, 2): Library not loaded: @rpath/libglib-2.0.0.dylib
Referenced from: /Users/name/anaconda3/envs/myenv/lib/libharfbuzz.0.dylib
Reason: Incompatible library version: libharfbuzz.0.dylib requires version 5601.0.0 or later, but libglib-2.0.0.dylib provides version 0.0.0
$ conda list
absl-py 0.11.0 py36h79c6626_0 conda-forge
appnope 0.1.2 py36h79c6626_0 conda-forge
argon2-cffi 20.1.0 py36h6941dd6_2 conda-forge
asn1crypto 1.4.0 pyh9f0ad1d_0 conda-forge
astor 0.8.1 pyh9f0ad1d_0 conda-forge
astunparse 1.6.3 pypi_0 pypi
async_generator 1.10 py_0 conda-forge
attrs 20.3.0 pyhd3deb0d_0 conda-forge
backcall 0.2.0 pyh9f0ad1d_0 conda-forge
backports 1.0 py_2 conda-forge
backports.functools_lru_cache 1.6.1 py_0 conda-forge
bitarray 1.6.0 pypi_0 pypi
bleach 3.2.1 pyh9f0ad1d_0 conda-forge
boost-cpp 1.70.0 hd59e818_1 conda-forge
branca 0.3.1 py_0 conda-forge
brotlipy 0.7.0 py36ha3de816_1001 conda-forge
bzip2 1.0.8 hc929b4f_4 conda-forge
c-ares 1.17.1 hc929b4f_0 conda-forge
ca-certificates 2020.12.5 h033912b_0 conda-forge
cachetools 4.2.1 pypi_0 pypi
cairo 1.16.0 h0ab9d94_1001 conda-forge
canmatrix 0.8 py_0 conda-forge
cchardet 2.1.7 py36h27176af_0 conda-forge
certifi 2020.12.5 py36h79c6626_1 conda-forge
cffi 1.14.4 py36h1b827b8_0 conda-forge
chardet 3.0.4 py36h2432673_1008 conda-forge
click 7.1.2 pyh9f0ad1d_0 conda-forge
click-plugins 1.1.1 py_0 conda-forge
cligj 0.7.1 pyhd8ed1ab_0 conda-forge
cloudpickle 1.3.0 py_0
cmake 3.12.2 haff7e42_0
cryptography 2.3.1 py36hdbc3d79_0
curl 7.61.1 ha441bb4_0
cycler 0.10.0 py_2 conda-forge
cytoolz 0.11.0 py36h7b4949f_1 conda-forge
dask-core 2020.12.0 pyhd8ed1ab_0 conda-forge
decorator 4.4.2 py_0 conda-forge
defusedxml 0.6.0 py_0 conda-forge
descartes 1.1.0 py_4 conda-forge
entrypoints 0.3 pyhd8ed1ab_1003 conda-forge
enum34 1.1.10 py36h9f0ad1d_2 conda-forge
expat 2.2.9 hb1e8313_2 conda-forge
fastparquet 0.5.0 py36h809c706_0 conda-forge
ffmpeg 4.0 h01ea3c9_0
fiona 1.7.12 py36h0dff353_0
flatbuffers 1.12 pypi_0 pypi
folium 0.10.1 py_0 conda-forge
fontconfig 2.13.1 h1027ab8_1000 conda-forge
freetype 2.10.4 h3f75d11_0 conda-forge
freexl 1.0.5 h0b31af3_1002 conda-forge
future 0.18.2 py36h79c6626_2 conda-forge
gast 0.3.3 pypi_0 pypi
gdal 2.2.4 py36h6440ff4_1
geographiclib 1.50 py_0 conda-forge
geojson 2.5.0 py_0 conda-forge
geopandas 0.6.1 py_0
geopy 2.1.0 pyhd3deb0d_0 conda-forge
geos 3.6.2 h0a44026_1004 conda-forge
gettext 0.19.8.1 haf92f58_1004 conda-forge
giflib 5.1.7 h01d97ff_1 conda-forge
glib 2.58.3 py36hb0ce7ff_1004 conda-forge
google-auth 1.27.0 pypi_0 pypi
google-auth-oauthlib 0.4.2 pypi_0 pypi
google-pasta 0.2.0 pyh8c360ce_0 conda-forge
graphite2 1.3.13 h2e338ed_1001 conda-forge
graphviz 2.42.3 h98dfb87_0 conda-forge
grpcio 1.32.0 pypi_0 pypi
gym 0.17.3 py36h9f0ad1d_0 conda-forge
h5py 2.10.0 pypi_0 pypi
harfbuzz 1.8.8 hb8d4a28_0
haversine 2.3.0 pypi_0 pypi
hdf4 4.2.13 h71d84a9_1004 conda-forge
hdf5 1.10.2 hc401514_3 conda-forge
icu 58.2 h0a44026_1000 conda-forge
idna 2.10 pyh9f0ad1d_0 conda-forge
imagecodecs-lite 2019.12.3 py36h8062767_3 conda-forge
imageio 2.9.0 py_0 conda-forge
imgkit 1.0.2 pypi_0 pypi
importlib-metadata 3.1.1 pyhd8ed1ab_0 conda-forge
importlib_metadata 3.1.1 hd8ed1ab_0 conda-forge
install 1.3.4 pypi_0 pypi
ipykernel 5.1.4 py36h39e3cac_0 anaconda
ipyleaflet 0.13.3 pyh9f0ad1d_0 conda-forge
ipython 7.12.0 py36h5ca1d4c_0 conda-forge
ipython_genutils 0.2.0 py_1 conda-forge
ipywidgets 7.5.1 py_0 conda-forge
jasper 2.0.14 h45d9283_1 conda-forge
jedi 0.17.2 py36h79c6626_1 conda-forge
jinja2 2.11.2 pyh9f0ad1d_0 conda-forge
joblib 0.17.0 py_0 conda-forge
jpeg 9d hbcb3906_0 conda-forge
json-c 0.13.1 h575e443_1002 conda-forge
json5 0.9.5 pyh9f0ad1d_0 conda-forge
jsonschema 3.2.0 py_2 conda-forge
jupyter_client 6.1.7 py_0 conda-forge
jupyter_contrib_core 0.3.3 py_2 conda-forge
jupyter_core 4.7.0 py36h79c6626_0 conda-forge
jupyter_latex_envs 1.4.6 py36h9f0ad1d_1001 conda-forge
jupyterlab 2.2.9 py_0 conda-forge
jupyterlab_pygments 0.1.2 pyh9f0ad1d_0 conda-forge
jupyterlab_server 1.2.0 py_0 conda-forge
kealib 1.4.7 h40e48e4_6
keplergl 0.2.2 pypi_0 pypi
keras 2.3.1 py36_0 conda-forge
keras-applications 1.0.8 py_1 conda-forge
keras-preprocessing 1.1.2 pyhd8ed1ab_0 conda-forge
kiwisolver 1.3.1 py36he46ecad_0 conda-forge
lcms2 2.11 h11f7e16_1 conda-forge
libblas 3.8.0 17_openblas conda-forge
libcblas 3.8.0 17_openblas conda-forge
libcurl 7.61.1 hf30b1f0_0
libcxx 11.0.0 h4c3b8ed_1 conda-forge
libdap4 3.19.1 h3d3e54a_0
libedit 3.1.20191231 h0678c8f_2 conda-forge
libffi 3.2.1 hb1e8313_1007 conda-forge
libgdal 2.2.4 h7b1ea53_1
libgfortran 3.0.1 0 conda-forge
libiconv 1.16 haf1e3a3_0 conda-forge
libkml 1.3.0 hed7d534_1010 conda-forge
liblapack 3.8.0 17_openblas conda-forge
libllvm10 10.0.1 h009f743_3 conda-forge
libnetcdf 4.6.1 h4e6abe9_2
libopenblas 0.3.10 h0794777_0
libopencv 3.4.2 h7c891bd_1
libopus 1.3.1 hc929b4f_1 conda-forge
libpng 1.6.37 h7cec526_2 conda-forge
libpq 10.6 hbe1e24e_1000 conda-forge
libprotobuf 3.14.0 hfd3ada9_0 conda-forge
libsodium 1.0.18 hbcb3906_1 conda-forge
libspatialindex 1.9.3 h4a8c4bd_3 conda-forge
libspatialite 4.3.0a ha12ebda_19
libssh2 1.8.0 h322a93b_4
libtiff 4.1.0 hca7d577_6 conda-forge
libuuid 1.0.3 h6bb4b03_2
libvpx 1.7.0 h378b8a2_0
libwebp-base 1.1.0 hbcb3906_3 conda-forge
libxml2 2.9.10 h7cdb67c_3
libxslt 1.1.34 h83b36ba_0
llvm-openmp 11.0.0 h73239a0_1 conda-forge
llvmlite 0.35.0 py36hf7e63e9_1 conda-forge
lxml 4.6.2 py36h34aa933_0 conda-forge
lz4 3.1.1 py36hcce9a2f_0 conda-forge
lz4-c 1.9.2 hb1e8313_3 conda-forge
markdown 3.3.3 pyh9f0ad1d_0 conda-forge
markupsafe 1.1.1 py36ha3de816_2 conda-forge
matplotlib 3.3.3 py36h79c6626_0 conda-forge
matplotlib-base 3.3.3 py36h50af36e_0 conda-forge
mdfreader 4.1 pypi_0 pypi
mistune 0.8.4 py36h6941dd6_1002 conda-forge
mpmath 1.1.0 pypi_0 pypi
msgpack 0.5.6 pypi_0 pypi
munch 2.5.0 py_0 conda-forge
natsort 7.1.0 pyhd8ed1ab_0 conda-forge
nbclient 0.5.1 py_0 conda-forge
nbconvert 6.0.7 py36h79c6626_3 conda-forge
nbformat 5.0.8 py_0 conda-forge
ncurses 6.2 h2e338ed_4 conda-forge
nest-asyncio 1.4.3 pyhd8ed1ab_0 conda-forge
networkx 2.5 py_0 conda-forge
nodejs 10.13.0 h0a44026_0
notebook 6.1.4 py36_0
numba 0.52.0 py36h2be6da3_0 conda-forge
numexpr 2.7.1 py36h72eec15_3 conda-forge
numpy 1.19.4 py36h08dc641_2 conda-forge
oauthlib 3.1.0 pypi_0 pypi
olefile 0.46 pyh9f0ad1d_1 conda-forge
opencv 3.4.2 py36h6fd60c2_1 anaconda
openjpeg 2.3.1 h6cbf5cd_3 conda-forge
openssl 1.0.2u h0b31af3_0 conda-forge
opt-einsum 3.3.0 pypi_0 pypi
overpy 0.4 py_0 conda-forge
packaging 20.7 pyhd3deb0d_0 conda-forge
pandas 1.1.5 py36h2be6da3_0 conda-forge
pandoc 2.11.2 hc929b4f_0 conda-forge
pandocfilters 1.4.2 py_1 conda-forge
parso 0.7.0 py_0
pathlib 1.0.1 py36_1
pcre 8.44 hb1e8313_0 conda-forge
pdfkit 0.6.1 pypi_0 pypi
pexpect 4.8.0 pyh9f0ad1d_2 conda-forge
pickleshare 0.7.5 py_1003 conda-forge
pillow 8.0.0 py36h1a82f1a_0 anaconda
pip 20.3.1 pyhd8ed1ab_0 conda-forge
pixman 0.38.0 h01d97ff_1003 conda-forge
poppler 0.67.0 hb974355_6 conda-forge
poppler-data 0.4.10 0 conda-forge
proj4 5.0.1 h1de35cc_0
prometheus_client 0.9.0 pyhd3deb0d_0 conda-forge
prompt-toolkit 3.0.8 pyha770c72_0 conda-forge
prompt_toolkit 3.0.8 hd8ed1ab_0 conda-forge
protobuf 3.14.0 py36h22858aa_0 conda-forge
psutil 5.7.3 pypi_0 pypi
ptyprocess 0.6.0 py_1001 conda-forge
py-opencv 3.4.2 py36h7c891bd_1
py4j 0.10.9 pypi_0 pypi
pyarrow 3.0.0 pypi_0 pypi
pyasn1 0.4.8 pypi_0 pypi
pyasn1-modules 0.2.8 pypi_0 pypi
pycparser 2.20 pyh9f0ad1d_2 conda-forge
pydot 1.4.1 pypi_0 pypi
pyglet 1.5.0 py36h9f0ad1d_1 conda-forge
pygments 2.7.3 pyhd8ed1ab_0 conda-forge
pyopenssl 19.0.0 py36_0
pyparsing 2.4.7 pyh9f0ad1d_0 conda-forge
pyproj 3.0.0.post1 pypi_0 pypi
pyrsistent 0.17.3 py36h6941dd6_1 conda-forge
pysocks 1.7.1 py36h2432673_2 conda-forge
pyspark 3.0.1 pypi_0 pypi
python 3.6.6 hc167b69_0
python-dateutil 2.8.1 py_0 conda-forge
python-snappy 0.5.4 py36h8d68209_3 conda-forge
python_abi 3.6 1_cp36m conda-forge
pytz 2020.4 pyhd8ed1ab_0 conda-forge
pywavelets 1.1.1 py36h809c706_3 conda-forge
pyyaml 5.3.1 py36ha3de816_1 conda-forge
pyzmq 20.0.0 py36h8302150_1 conda-forge
readline 7.0 hcfe32e1_1001 conda-forge
requests 2.25.0 pyhd3deb0d_0 conda-forge
requests-oauthlib 1.3.0 pypi_0 pypi
rhash 1.3.6 haf1e3a3_1001 conda-forge
rsa 4.7.1 pypi_0 pypi
rtree 0.9.4 py36h49c2f37_2 conda-forge
scikit-image 0.17.2 py36h81aa140_0 anaconda
scikit-learn 0.23.2 py36h751d9b8_3 conda-forge
scipy 1.2.1 py36hbd7caa9_1 conda-forge
seaborn 0.11.0 py_0 anaconda
selenium 3.141.0 py36h9de38fb_1002 conda-forge
send2trash 1.5.0 py_0 conda-forge
setuptools 49.6.0 py36h2432673_2 conda-forge
shapely 1.7.1 pypi_0 pypi
six 1.15.0 pyh9f0ad1d_0 conda-forge
snappy 1.1.8 hb1e8313_3 conda-forge
sqlite 3.33.0 hffcf06c_0
sympy 1.6.2 pypi_0 pypi
tensorboard 2.4.1 pypi_0 pypi
tensorboard-plugin-wit 1.8.0 pypi_0 pypi
tensorflow 2.4.1 pypi_0 pypi
tensorflow-base 1.14.0 py36h9f0ad1d_0 conda-forge
tensorflow-estimator 2.4.0 pypi_0 pypi
termcolor 1.1.0 py_2 conda-forge
terminado 0.9.1 py36h79c6626_1 conda-forge
testpath 0.4.4 py_0 conda-forge
theano 0.8.2 py36_0 conda-forge
threadpoolctl 2.1.0 pyh5ca1d4c_0 conda-forge
thrift 0.11.0 py36h4a8c4bd_1001 conda-forge
tifffile 2019.7.26.2 py36_0 conda-forge
tk 8.6.10 hb0a8c7a_1 conda-forge
toolz 0.11.1 py_0 conda-forge
tornado 6.1 py36h6941dd6_0 conda-forge
traitlets 4.3.3 py36h9f0ad1d_1 conda-forge
traittypes 0.2.1 pyh9f0ad1d_2 conda-forge
turfpy 0.0.5 pyhd8ed1ab_0 conda-forge
typing-extensions 3.7.4.3 pypi_0 pypi
urllib3 1.25.11 py_0 conda-forge
utm 0.7.0 pypi_0 pypi
vincent 0.4.4 py_1 conda-forge
wcwidth 0.2.5 pyh9f0ad1d_2 conda-forge
webencodings 0.5.1 py_1 conda-forge
werkzeug 1.0.1 pyh9f0ad1d_0 conda-forge
wheel 0.36.1 pyhd3deb0d_0 conda-forge
widgetsnbextension 3.5.1 py36h79c6626_4 conda-forge
wrapt 1.12.1 py36h7b4949f_2 conda-forge
xerces-c 3.2.2 h4db8090_1003 conda-forge
xlrd 1.2.0 pyh9f0ad1d_1 conda-forge
xlsxwriter 1.3.7 pyh9f0ad1d_0 conda-forge
xlwt 1.3.0 py_1 conda-forge
xz 5.2.5 haf1e3a3_1 conda-forge
yaml 0.2.5 haf1e3a3_0 conda-forge
zeromq 4.3.3 h74dc148_3 conda-forge
zipp 3.4.0 py_0 conda-forge
zlib 1.2.11 h7795811_1010 conda-forge
zstd 1.4.5 h289c70a_2 conda-forge
$ conda info
active environment : myenv
active env location : /Users/name/anaconda3/envs/myenv
shell level : 2
user config file : /Users/name/.condarc
populated config files : /Users/name/.condarc
conda version : 4.9.2
conda-build version : 3.18.11
python version : 3.7.6.final.0
virtual packages : __osx=10.15.4=0
__unix=0=0
__archspec=1=x86_64
base environment : /Users/name/anaconda3 (writable)
channel URLs : https://conda.anaconda.org/conda-forge/osx-64
https://conda.anaconda.org/conda-forge/noarch
https://repo.anaconda.com/pkgs/main/osx-64
https://repo.anaconda.com/pkgs/main/noarch
https://repo.anaconda.com/pkgs/r/osx-64
https://repo.anaconda.com/pkgs/r/noarch
package cache : /Users/name/anaconda3/pkgs
/Users/name/.conda/pkgs
envs directories : /Users/name/anaconda3/envs
/Users/name/.conda/envs
platform : osx-64
user-agent : conda/4.9.2 requests/2.25.0 CPython/3.7.6 Darwin/19.4.0 OSX/10.15.4
UID:GID : 501:20
netrc file : None
offline mode : False
我刚刚创造了一个新环境,一切都很顺利。