<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<oembed>
  <author_name>y-kamiya</author_name>
  <author_url>https://blog.hatena.ne.jp/y-kamiya/</author_url>
  <blog_title>MEMOcho-</blog_title>
  <blog_url>https://jsapachehtml.hatenablog.com/</blog_url>
  <categories>
  </categories>
  <description>pngで受け取った画像をjpgに変換して使いたい場面があったためメモ 一度ファイルとして保存すればもちろんOKだが特にファイルにする必要がなかったためその方法を探した そのものずばりなのがあった python: Convert from PNG to JPG without saving file to disk using PIL - Stack Overflow BytesIOを使えばOK （stackoverflowより引用） from io import BytesIO def convertToJpeg(im): with BytesIO() as f: im.save(f, for…</description>
  <height>190</height>
  <html>&lt;iframe src=&quot;https://hatenablog-parts.com/embed?url=https%3A%2F%2Fjsapachehtml.hatenablog.com%2Fentry%2F2020%2F04%2F12%2F220901&quot; title=&quot;pythonでpng -&amp;gt; jpgの変換 - MEMOcho-&quot; class=&quot;embed-card embed-blogcard&quot; scrolling=&quot;no&quot; frameborder=&quot;0&quot; style=&quot;display: block; width: 100%; height: 190px; max-width: 500px; margin: 10px 0px;&quot;&gt;&lt;/iframe&gt;</html>
  <image_url></image_url>
  <provider_name>Hatena Blog</provider_name>
  <provider_url>https://hatena.blog</provider_url>
  <published>2020-04-12 22:09:01</published>
  <title>pythonでpng -&gt; jpgの変換</title>
  <type>rich</type>
  <url>https://jsapachehtml.hatenablog.com/entry/2020/04/12/220901</url>
  <version>1.0</version>
  <width>100%</width>
</oembed>
