Fix context duplication in pdf output
This commit is contained in:
1 parent
370f3252ef
commit
3754c0c11a
4 files changed
+53
-37
No files matched your search
+1
-1
@@ -70,7 +70,7 @@ def pdf_images_of_contexts(root_dir, label, all_labels):
|
||||
|
||||
pertinent_contexts = []
|
||||
|
||||
for filename in os.listdir(text2_dir):
|
||||
for filename in sorted(os.listdir(text2_dir)):
|
||||
if filename.startswith("CTXT ") and filename.endswith(".pdf"):
|
||||
# Extract "first_label -> last_label" from "CTXT first_label -> last_label.pdf"
|
||||
core = filename[5:-4]
|
||||
|
||||
Reference in new issue
Block a user