Implement per-entry patches 2

This commit is contained in:
Hans5958 2023-06-15 21:45:29 +07:00
parent 978757ce8f
commit 1c1662a837

View file

@ -9,25 +9,25 @@
atlas_ids = {}
authors = []
with open('../web/all-authors.txt', 'r') as authors_file:
with open('../web/all-authors.txt', 'r', encoding='utf-8') as authors_file:
authors = authors_file.read().strip().split()
with open('../web/read_ids.txt', 'r') as ids_file:
with open('../data/read-ids.txt', 'r', encoding='utf-8') as ids_file:
out_ids = ids_file.read().strip().split()
with open('../web/atlas.json', 'r', encoding='utf-8') as atlas_file:
atlas_data = json.loads(atlas_file.read())
format_all_entries(atlas_file)
# format_all_entries(atlas_file)
base_image_path = os.path.join('..', 'web', '_img', 'canvas', 'place30')
ScaleConfig.image1 = os.path.join(base_image_path, '159.png')
scale_back.swap_source_dest('164', '165', os.path.join(base_image_path, '163_159.png'))
scale_back.scale_back_entries(atlas_file)
scale_back.swap_source_dest('165', '166', os.path.join(base_image_path, '164_159.png'))
scale_back.scale_back_entries(atlas_file)
scale_back.swap_source_dest('166', '167', os.path.join(base_image_path, '165_159.png'))
scale_back.scale_back_entries(atlas_file)
# base_image_path = os.path.join('..', 'web', '_img', 'canvas', 'place30')
# ScaleConfig.image1 = os.path.join(base_image_path, '159.png')
# scale_back.swap_source_dest('164', '165', os.path.join(base_image_path, '163_159.png'))
# scale_back.scale_back_entries(atlas_file)
# scale_back.swap_source_dest('165', '166', os.path.join(base_image_path, '164_159.png'))
# scale_back.scale_back_entries(atlas_file)
# scale_back.swap_source_dest('166', '167', os.path.join(base_image_path, '165_159.png'))
# scale_back.scale_back_entries(atlas_file)
last_id = 0