Tag Archives: image

[Solved] AttributeError: ‘PngImageFile‘ object has no attribute ‘imshow‘

How to solve error attributeerror:’pngimagefile’object has no attribute’imshow’ Successfully.


Error:

AttributeError: ‘PngImageFile’ object has no attribute ‘imshow’

Reasons:

Attribute error: the “pngimagefile” object does not have the attribute “imshow”

Solution:

Pngimagefile does not have imshow method, but has show method, so the following changes are required!

Modify
img.imshow()
to
img.show()

Docker Create tomcat Error standard_init_linux.go:211: exec user process caused “no such file or directory”

Using the command before Tomcat creates a container

docker pull tomcat
docker run -it -P tomcat

Report the following error: Standard_ init_ linux.go:211 : exec user process caused “no such file or directory”

Solution:

Use other Tomcat images to create Tomcat container and run it successfully

docker run -d --name tomcat -p 8888:8080 registry.cn-hangzhou.aliyuncs.com/youdao/tomcat

Speculation: before using the docker hub with the highest number of stars, there was a problem, indicating that this kind of file and directory could not be found. Maybe the image was damaged when downloading

If we use the new container to download and run, it’s OK

Personal test!!! This error is the download image is damaged! The docker needs to be unloaded clearly. Remember to clear all the associated file directories

[docker] error in deleting image: image is referenced in multiple repositories

Error in deleting according to image ID:

[root@master-gxf zipkin-ui]# docker rmi 66ce95468449
Error response from daemon: conflict: unable to delete 66ce95468449 (must be forced) - image is referenced in multiple repositories

Docker images finds that the same image ID is tagged into multiple different warehouses

[root@master-gxf zipkin-ui]# docker images
REPOSITORY                                 TAG                 IMAGE ID            CREATED             SIZE
blanchedingding/zipkin-ui                  logvisualization    66ce95468449        23 minutes ago      78.8MB
doraemon/zipkin-ui                         logvisualization    66ce95468449        23 minutes ago      78.8MB
zipkin-ui                                  latest              66ce95468449        23 minutes ago      78.8MB

Use R epository:tag You can delete it in the following way:

[root@master-gxf zipkin-ui]# docker rmi doraemon/zipkin-ui:logvisualization
Untagged: doraemon/zipkin-ui:logvisualization
[root@master-gxf zipkin-ui]# docker images
REPOSITORY                                 TAG                 IMAGE ID            CREATED             SIZE
blanchedingding/zipkin-ui                  logvisualization    66ce95468449        25 minutes ago      78.8MB
zipkin-ui                                  latest              66ce95468449        25 minutes ago      78.8MB