dfe171249a251094498f4f17902f2486eb2fa941,lib/streamlit/elements/image_proto.py,,_bytes_to_b64,#Any#Any#Any#,69

Before Change


        image = Image.open(io.BytesIO(data))
        w, h = image.size
        if w > width:
            image = image.resize((width, int(1.0 * h * width / w)))
            data = _PIL_to_bytes(image, format=format, quality=80)

            if format is None:

After Change


    if width > 0:
        if actual_width > width:
            new_height = int(1.0 * actual_height * width / actual_width)
            image = image.resize((width, new_height))
            data = _PIL_to_bytes(image, format=format, quality=90)

            if format is None:
                mime_type = "image/png"
Italian Trulli
In pattern: SUPERPATTERN

Frequency: 3

Non-data size: 4

Instances


Project Name: streamlit/streamlit
Commit Name: dfe171249a251094498f4f17902f2486eb2fa941
Time: 2019-08-28
Author: arraydude@gmail.com
File Name: lib/streamlit/elements/image_proto.py
Class Name:
Method Name: _bytes_to_b64


Project Name: AKSHAYUBHAT/DeepVideoAnalytics
Commit Name: 9fab60f76afc4220876f5c7aaa39546b7c3661d4
Time: 2017-02-21
Author: akshayubhat@gmail.com
File Name: dvalib/pyscenecustom/__init__.py
Class Name:
Method Name: detect_scenes


Project Name: wkentaro/labelme
Commit Name: 512d9affe75ccddf666ee932acc6bd56d00ce6e7
Time: 2018-02-06
Author: www.kentaro.wada@gmail.com
File Name: labelme/utils.py
Class Name:
Method Name: draw_label