Skip to content

Generating a pdf from a graph truncates the image #2481

Closed

Description

@rchiodo

Create a plot that's rather wide (I used this code below):

#%%
from time import sleep
import numpy as np

from livelossplot import PlotLosses

#%%
liveplot = PlotLosses()

for i in range(20):
    liveplot.update({
        'accuracy': 1 - np.random.rand() / (i + 2.),
        'val_accuracy': 1 - np.random.rand() / (i + 0.5),
        'mse': 1. / (i + 2.),
        'val_mse': 1. / (i + 0.5)
    })
    liveplot.draw()
    sleep(1.)

Open the plot viewer
export to PDF

Expected result:
Full image is in the PDF.

Actual result:
image

Activity

  1. greazer commented on Feb 15, 2020

    @greazer
    Contributor

    Not killer, but I would argue that this significantly affects the usefulness of "export to pdf"

  2. rchiodo commented on Mar 16, 2020

    @rchiodo
    ContributorAuthor

    Validated

  3. locked as resolved and limited conversation to collaborators on Mar 27, 2020
  4. unlocked this conversation on Nov 13, 2020
  5. locked as resolved and limited conversation to collaborators on May 7, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Labels

No labels
No labels

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions