Ask Your Question
1

Image.PNG definition degraded, in notebook view

asked 2018-12-16 15:26:19 +0100

ortollj gravatar image

Hi is there a way to improve the definition in Jupyter notebook ?

from PIL import Image
img=Image.open("C:\\Users\\jean-pierre\\Documents\\SageMath\\IPYNB\\"+"Satellites.png")
matrix_plot(img, origin='upper',aspect_ratio=1)

image description

what I see in notebook is very poor in notebook !

edit retag flag offensive close merge delete

1 Answer

Sort by ยป oldest newest most voted
1

answered 2018-12-19 08:56:23 +0100

ortollj gravatar image

it 's ok !, searching on the web, I found :matplotlib.org I use this code:

import matplotlib.pyplot as plt
import matplotlib.image as mpimg
import numpy as np
img = mpimg.imread("C:\\Users\\jean-pierre\\Documents\\SageMath\\IPYNB\\"+"Satellites.png")
imgplot = plt.imshow(img)

the definition is ok with this code

edit flag offensive delete link more

Comments

change figure size

from matplotlib.pyplot import figure
figure(num=None, figsize=(20, 10), dpi=100, facecolor='w', edgecolor='k')
ortollj gravatar imageortollj ( 2019-01-20 23:30:57 +0100 )edit

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Question Tools

1 follower

Stats

Asked: 2018-12-16 15:26:19 +0100

Seen: 474 times

Last updated: Dec 19 '18