-sod--open-604- ----- 500 Sex 2006-05-04.avi 【90% Plus】

It sounds like you’re referencing a filename that includes what might be a misformatted or placeholder string ( -SOD--OPEN-604- ----- 500 SEX 2006-05-04.avi ).

# Remove codes, dashes, and potentially unwanted words (like "SEX") clean_name = re.sub(r'[-_]+', ' ', name) clean_name = re.sub(r'\bSEX\b', '', clean_name, flags=re.IGNORECASE) clean_name = re.sub(r'\s+', ' ', clean_name).strip() -SOD--OPEN-604- ----- 500 SEX 2006-05-04.avi

return new_path if name == " main ": folder = "." # Change to your folder for f in os.listdir(folder): if f.lower().endswith(".avi") and "SEX" in f.upper(): full_path = os.path.join(folder, f) normalize_video_filename(full_path, dry_run=False) It sounds like you’re referencing a filename that

if not dry_run: os.rename(filepath, new_path) print(f"Renamed: {filename} -> {new_filename}") else: print(f"[DRY RUN] Would rename: {filename} -> {new_filename}") name) clean_name = re.sub(r'\bSEX\b'

Image

For more than three decades, Drastic™ has been developing cutting edge digital video solutions for television, post production and sports broadcasting, from real time web delivery to 8K broadcast.

We offer standalone software for the end user or enterprise, integrated solutions for automated workflows, and OEM tools for custom applications or branded devices.

Contact Us

Address:
523 The Queensway, Suite 201
Toronto, ON
M8Y 1J7, Canada

Phone: +1 (416) 255 5636

Email:

Fax: + 1 (416) 255 8780

Follow us on Social Media

twitter facebook instagram linkedin youtube