Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions CHANGES
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
## 0.17.5 (in progress)
- fix pypdf2 replace deprecated PdfFileMerger with PdfMerger

## 0.17.4 (2025-03-17)
- fix deprecated pandas indexing fallback #346

Expand Down
2 changes: 1 addition & 1 deletion tobias/__init__.py
Original file line number Diff line number Diff line change
@@ -1 +1 @@
__version__ = "0.17.4"
__version__ = "0.17.5"
6 changes: 3 additions & 3 deletions tobias/tools/plot_tracks.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
import argparse
import numpy as np

from PyPDF2 import PdfFileMerger, PdfFileReader
from PyPDF2 import PdfMerger, PdfReader
import matplotlib
from matplotlib import textpath
from matplotlib.font_manager import findfont, FontProperties
Expand Down Expand Up @@ -388,11 +388,11 @@ def run_tracks(args):
output_plots.append(pa.config["output_filename"])

#Done plotting all regions; join to one pdf
merger = PdfFileMerger(strict=False)
merger = PdfMerger(strict=False)
pdf_filenames = [prefix + ".pdf" for prefix in output_plots]
for pdf in pdf_filenames:
if os.stat(pdf).st_size != 0: #only join files containing plots
merger.append(PdfFileReader(pdf))
merger.append(PdfReader(pdf))
merger.write(os.path.join(args.outdir, "all_plots.pdf"))

#End PlotTracks
Expand Down