[Anime] Convert Absolute to SxE numbers

How-to guides, frequently asked questions, not-so-obvious features, etc
Locked
User avatar
rednoah
The Source
Posts: 21076
Joined: 16 Nov 2011, 08:59

[Anime] Convert Absolute to SxE numbers

Post by rednoah »

Convert Absolute to SxE numbers

Anime files are often named using Absolute numbering. However, most Media Center Software like Plex or Kodi require SxE naming standards that match the TheTVDB standard Airdate SxE numbers. So in order to help TheTVDB scrapers correctly identify Anime episodes you will have to convert Absolute Anime numbers to their corresponding TheTVDB Airdate SxE numbers.




Option A: Use the dynamic {db} binding to match AniDB / Absolute episodes to TheTVDB / Airdate SxE episodes:

e.g. You may use the {db} database cross-reference binding to transform AniDB matches to TheTVDB matches:

Code: Select all

{db.TheTVDB.plex.name}
:idea: Note that ImageImage mapping information is maintained by the Anime-Lists/anime-lists project.
Image




Option B: Use the dynamic {order} binding to match TheTVDB / Absolute episodes to TheTVDB / Airdate SxE episodes:

In the best case, if absolute number information has already been added to TheTVDB and you have clearly named files (e.g. E501) then FileBot can easily match the absolute numbers with the correct episode in Airdate order and rename it using SxE information (e.g. S14E19). In the worst case, especially if files use ambiguous naming patterns (e.g. 501 can mean 5x01 or 501) you may need to:
  1. Match with Absolute Order episode information using TheTVDB
  2. Translate Absolute Order episode data to Airdate Order in the format

e.g. use the dynamic {order} binding to rebase bindings such as {plex} or {sxe} to Airdate SxE episode information in your custom format:

Code: Select all

{order.airdate.plex}

Code: Select all

{order.airdate.plex.name}

Code: Select all

{order.airdate.sxe}
:idea: You can use the Presets feature to create your own Convert Absolute to Airdate preset for easy access.
Image

:idea: The same technique can be used to convert DVD SxE numbers to Airdate SxE numbers and vice versa.




Option C: Use the --mapper command-line option to match files with one order but rename with another order:

e.g. match episodes by absolute episode number via the --mapper option and then rename files using the default Airdate SxE Order episode information:

Code: Select all

$ filebot -rename *.mkv --db TheTVDB --mapper order.absolute.episode --format "{n} - {s00e00} - E{absolute}" -non-strict
[MOVE] Rename [One Piece 501.mkv] to [One Piece - S14E20 - E501.mkv]

e.g. match episodes based on ImageImage mapping information maintained by the Anime-Lists/anime-lists project via the --mapper option:

Code: Select all

$ filebot -rename *.mkv --db TheTVDB --mapper AnimeList.AniDB -non-strict
[MOVE] from [One Piece 501.mkv] to [One Piece - 14x20 - The Flames Are Lit - The Gray Terminal's Crisis.mkv]
:arrow: Please read Use --mapper expressions for AniDB / TheTVDB cross-entity matching for details and advanced usage examples.




Option D: Use the --filter command-line option to explicitly match the one episode that was aired this week:

Please read the amc script manual for details:
rednoah wrote: 01 Aug 2012, 13:04 You can (and should) force Movie / Series / Anime mode by setting --def ut_label, and you can further define your own --filter rules to fine-tune matching to your exact needs, and avoid mismatches. For example, if one show is confused with another due to bad naming or missing data you can simply exclude the bad one, or if you only process recently aired episodes, then you could exclude episodes that have not aired recently from matching.

e.g. if you only process recently aired episodes you can virtually guarantee 100% auto-detection accuracy by adding simple filter rules such as these:

Code: Select all

--filter "age < 5" --def "ut_label=TV"

e.g. use an age filter to match the given file to whichever episode was aired this week irregardless of naming and numbering:

Code: Select all

$ filebot -rename *.mp4 --db TheTVDB --filter "age < 5" -non-strict
[MOVE] from [Kimetsu no Yaiba - Yuukaku-hen - Part C.mp4] to [Demon Slayer Kimetsu no Yaiba - 3x03 - What Are You.mp4]
:!: --filter "age < 5" means that you know in advance and can thus guarantee that you will only ever process newly aired episodes within days of the release date.
:idea: Please read the FAQ and How to Request Help.
Locked