2

I can show rgba image using pyplot.imshow(image,alpha=0.8).

I tried to save image using pyplot.savefig(), but image included padding is saved.

I want to save only image which not have padding.

gameon67
  • 3,981
  • 5
  • 35
  • 61

1 Answers1

1

can you use: pyplot.savefig() instead of pyplot.saveconfig()? if yes, then you can use bbox_inches='tight' to remove or reduce margins and padding around the image: solution one:
pyplot.savefig('test.png', bbox_inches='tight')

U13-Forward
  • 69,221
  • 14
  • 89
  • 114
parvaneh shayegh
  • 507
  • 5
  • 13
  • .Thank you for reply. Your answer very nice!! i have typo, and i edited saveconfig() to savefig().i want to vote, but i cant. becuz not enough my point... – DongHwan Shin Jul 16 '18 at 02:41