Skip to content

Commit

Permalink
add rename image and output new file matched list
Browse files Browse the repository at this point in the history
  • Loading branch information
aimuch committed Jan 20, 2021
1 parent 868f456 commit a911b3e
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions rename_img_list.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@
import sys
import argparse
import random
from tqdm import tqdm

matched_list_path = "./match_list.txt"

Expand All @@ -28,7 +27,7 @@ def rename(srcPath, dstPath, matchedListPath):
print(matchedListPath)
srcList = os.listdir(srcPath)
outputFile = open(matchedListPath,'w+')
for i, f in tqdm(enumerate(srcList)):
for i, f in enumerate(srcList):
fileInfo = f.split(".")
srcFilePath = os.path.join(srcPath, f)
dstFilePath = os.path.join(dstPath, str(i)+"."+fileInfo[-1])
Expand Down

0 comments on commit a911b3e

Please sign in to comment.