If you have not already, we suggest setting your Plex username to something else rather than email which is displayed on your posts in forum. You can change the username at https://app.plex.tv/desktop#!/account
Welcome to our forums! Please take a few moments to read through our Community Guidelines (also conveniently linked in the header at the top of each page). There, you'll find guidelines on conduct, tips on getting the help you may be searching for, and more!

[Release] HTTP Anidb Metadata Agent (HAMA)

1246781

Comments

  • sparanoidsparanoid Posts: 7Members, Plex Pass Plex Pass
    edited April 2014

    Thanks for your great plugin, but I have some problem when using it:

    I keep my anime folder structure like this with some automatic scripting:

    https://www.dropbox.com/s/q3tm82o991owg22/Screenshot%202014-04-10%2001.50.17.png

    But Hama seems can't find any media info unless I changed the folder name to Romaji. 

    I see it has multiple language support, but I still can't get it working. I'm I doing something wrong?

    Thanks again.

  • ZeroQIZeroQI Posts: 1,225Members ✭✭✭

    Hi all.

    I have been working thanks to AtomicStrawberry back on the agent for the following working functionalities:

       . Settigns in the agent directly now

      . If you search manually "aid:" adding the anidb id it will bypass all search in case you have issues [fixed]

       . automatic xml file download using 2 week cache (use aid:xxxxx with aid being the anidb id in the url if serie not picked up)

       . Correct TVdb season posters downloaded for poster and season

       . AniDB poster if selected present at the end

       . Moved XML to Data folders for troubleshooting, gets pulled from the cache, but you can cross reference logs that way

       . local cache for mp3 themes using AniDB id.mp3 convention. If MP3s are placed in Plug-in Support/Data/Hama/com.plexapp.agents.hama/DataItems/Theme Songs/Anidb-id.mp3

       . Anime average duration [fixed], thanks for reporting (comparison with 1 instead of "1" was the cause)

       . shows all posters regardless of the language

       . Aditionnaly, title can be selected of a serie in languages and main select main anidb title, which i recommend using.

    Please use BABS scanner, there have been a couple nice fixes: 

    https://forums.plex.tv/topic/31081-better-absolute-scanner-babs/page-2

    It should recognise most folders names and give a poster.

       . Please post folder names which are labeled as AniDB and failed being picked up automatically

       . Should i save locally in Plex data folder the fanart to avoid re-downloading like i do for the theme?

       . this should avoid issues with files outdated.

       . Let me know issues with this version. I use the tv series category for everything and seem to work ok.

    Absolute Series Scanner (ASS): Seasons+Absolute mode series scanner managing subdirectories and AniDB type specials,with a logging off all files (skipped on top of root folder, then sorted one line per file with regex used and info, all series sorted alphabetically) and one with the filelist to reproduce the library on my end with dummy files. It also add all files and recognise specials pretty accurately.

    http AniDB Metadata Agent (HAMA): Some good info there, will have to re-write it at some point... Data folders are kinda mandatory... Huge libraries can fetch 10gb in space. If you have no poster but other metadata is showing, create "Plug-in Support/Data/com.plexapp.agents.hama/DataItems" agent folders as indicated in the readme on GitHub

    Impressed by the agent recognition rate? Consider donating few euros through Paypal: Absolute Series Scanner + HTTP AniDB Metadata Agent. (Donators: xnaas, Sven-7, Niegen, Vorador, Fratal, T. Mayville,  A. Estremera, KJKingJ. Thanks guys)

  • ZeroQIZeroQI Posts: 1,225Members ✭✭✭
    edited April 2014

    Recent Improvements:

       . Zip files contain folder structure for Data folder. without that, no posters... However, even if you re-create the category and re-scan, no need to download posters again, way faster

       . Just work with no fuss on folders names in Kanjis [Sparanoid thanks for reporting, it never worked before but that made me want to do it]

       . Use the syntax "aid:2656:アフロサムライ" or "aid:2656" and selecting "ja" instead of "main" as first language in the agent settings, will make the title stays in Kanji. Beware of caching however, as changing the language can retain the previous title.... you need to delete all, empty trash, clean bundles, restart scanning from scratch
       . Local themes and poster cache, once downloaded, never gets downloaded again
       . Allow for replacement of mp3 themes
       . Enables all languages and synonym lookup, and strangely seem faster since it recognize way more series in seconds
       . AniDB posters can be enabled or disabled from the agent settings window, just like the TVDB posters, banners, and the language selection for the title and episodes (ja in in Kanji, x-jat is in Romaji, main is the main title in anidb)
       . 2 week cache for XML files. can use aid:xxxxx to force anime if not detected. Do we need to restart the agent afterwards to cache again? i don't know yet...
       . average episode length working back.
       . punctuation is better handled
     
    A lot changed in a week, thanks to AtomicStrawberry giving me back a bit of my apetite for programming and by few peoples that just reported issues, like the Kanji not working... Not aware of other agents with that working :D
     
    I don't recommend downloading the AniDB cover since it's rarely there and not normalised
    Please let me know if you like this one, and if it is faster that before and any other agent. the recognition rate should have jumped significantly since it checks synonyms and all languages unlike before. Please feedback, as it is only available here, also improvement requests are welcome. The code is on github

    Absolute Series Scanner (ASS): Seasons+Absolute mode series scanner managing subdirectories and AniDB type specials,with a logging off all files (skipped on top of root folder, then sorted one line per file with regex used and info, all series sorted alphabetically) and one with the filelist to reproduce the library on my end with dummy files. It also add all files and recognise specials pretty accurately.

    http AniDB Metadata Agent (HAMA): Some good info there, will have to re-write it at some point... Data folders are kinda mandatory... Huge libraries can fetch 10gb in space. If you have no poster but other metadata is showing, create "Plug-in Support/Data/com.plexapp.agents.hama/DataItems" agent folders as indicated in the readme on GitHub

    Impressed by the agent recognition rate? Consider donating few euros through Paypal: Absolute Series Scanner + HTTP AniDB Metadata Agent. (Donators: xnaas, Sven-7, Niegen, Vorador, Fratal, T. Mayville,  A. Estremera, KJKingJ. Thanks guys)

  • MehdroidMehdroid Posts: 10Members, Plex Pass Plex Pass

    Hi!

    I am using Hama with BABS! Thank you for the work :) I like the choice to get art from TVDB and how the titles of the episodes look. Really liking it.   :)

  • ZeroQIZeroQI Posts: 1,225Members ✭✭✭
    edited April 2014

    Thanks Mehdroid! the other anidb agent use an account, file checksum, no posters, no episode summaries so of course this one is better :D

    I looked into "steins;gate" and other titles with a semi-colon, and i unfortunaltly cannot fix fully... as the title received by the agent is "Steins" if the search string is "Steins;gate", but i changed something so the keyword search can pick it up, just not a 100% match so has to be manually updated, but it picks it up without modifying anything. Good enough...

     K-On! and K-On!! and titles with years works ok now (changed agent to make a direct comparison without substitution and one with substitutions,  Key word search should pick it up if fails... so i need people to update their agent and test...  You can always use aid:xxxx with xxxx being the anidb id (at the end of the URL) for manual assignment shall any serie not be found (please feedback if that is the case)

    Created a list for missing episodes (same as other logs, in data folder where i keep a cache of the theme songs posters and fanart, Support added for specials. specials not in anidb gets their episode number as title (too much code rewrite to change that, would have to change from parsing the xml to parsing metadata scanned files, wouldn't be optimized)

    Support for OPs/EDs, trailers, etc.
    OPs/EDs "C": Season 0 Episodes 101-199 (e.g. anidb C1 => S00e101)

    Trailers "T": Season 0 Episodes 201-299 (anidb T1 => S00e201, T2 => s00e02, ...)
    Parodies "P": Season 0 Episodes 301-399  (anidb P1 => S00e301, P2 => s00e302, ...)
    Other "O": Season 0 Episodes 401-499     (anidb O1 => S00e401, O2 => s00e402, ...)

    Few Plex bugs: you need to change view while in serie season 0 to list new detected files, need to go on ep to refresh title.

    Should only affect refreshes, not the first detection

     

    Just replace __init__.py with the code on github

    Tests were done with a kanji folder name so seem to be pretty stable... Please feedback any issue or functionality wished...

    Please update the database using the logs, series without posters would have a link to update... Hold on few months for theme songs, plex team will update their backlog (oldest has been submited a year ago still not integrated)

    Absolute Series Scanner (ASS): Seasons+Absolute mode series scanner managing subdirectories and AniDB type specials,with a logging off all files (skipped on top of root folder, then sorted one line per file with regex used and info, all series sorted alphabetically) and one with the filelist to reproduce the library on my end with dummy files. It also add all files and recognise specials pretty accurately.

    http AniDB Metadata Agent (HAMA): Some good info there, will have to re-write it at some point... Data folders are kinda mandatory... Huge libraries can fetch 10gb in space. If you have no poster but other metadata is showing, create "Plug-in Support/Data/com.plexapp.agents.hama/DataItems" agent folders as indicated in the readme on GitHub

    Impressed by the agent recognition rate? Consider donating few euros through Paypal: Absolute Series Scanner + HTTP AniDB Metadata Agent. (Donators: xnaas, Sven-7, Niegen, Vorador, Fratal, T. Mayville,  A. Estremera, KJKingJ. Thanks guys)

  • MehdroidMehdroid Posts: 10Members, Plex Pass Plex Pass

    Question (probably a easy one....) :

    Does Hama search filenames with "_" and/or "." used as separators?

  • MehdroidMehdroid Posts: 10Members, Plex Pass Plex Pass
    ZeroQI wrote on April 13 2014, 8:58 AM: »

    Thanks Mehdroid! the other anidb agent use an account, file checksum, no posters, no episode summaries so of course this one is better :D

    I looked into "steins;gate" and other titles with a semi-colon, and i unfortunaltly cannot fix fully... as the title received by the agent is "Steins" if the search string is "Steins;gate", but i changed something so the keyword search can pick it up, just not a 100% match so has to be manually updated, but it picks it up without modifying anything. Good enough...

     K-On! and K-On!! and titles with years works ok now (changed agent to make a direct comparison without substitution and one with substitutions,  Key word search should pick it up if fails... so i need people to update their agent and test...  You can always use aid:xxxx with xxxx being the anidb id (at the end of the URL) for manual assignment shall any serie not be found (please feedback if that is the case)

    Created a list for missing episodes (same as other logs, in data folder where i keep a cache of the theme songs posters and fanart, Support added for specials. specials not in anidb gets their episode number as title (too much code rewrite to change that, would have to change from parsing the xml to parsing metadata scanned files, wouldn't be optimized)

    Support for OPs/EDs, trailers, etc.
    OPs/EDs "C": Season 0 Episodes 101-199 (e.g. anidb C1 => S00e101)

    Trailers "T": Season 0 Episodes 201-299 (anidb T1 => S00e201, T2 => s00e02, ...)
    Parodies "P": Season 0 Episodes 301-399  (anidb P1 => S00e301, P2 => s00e302, ...)
    Other "O": Season 0 Episodes 401-499     (anidb O1 => S00e401, O2 => s00e402, ...)

    Few Plex bugs: you need to change view while in serie season 0 to list new detected files, need to go on ep to refresh title.

    Should only affect refreshes, not the first detection

     

    Just replace __init__.py with the code on github

    Tests were done with a kanji folder name so seem to be pretty stable... Please feedback any issue or functionality wished...

    Please update the database using the logs, series without posters would have a link to update... Hold on few months for theme songs, plex team will update their backlog (oldest has been submited a year ago still not integrated)

    I will check it out now :) Thanks for the update

  • ZeroQIZeroQI Posts: 1,225Members ✭✭✭
    line 11 and 12:
    SPLIT_CHARS = [';', ':', '*', '?', ',', '.', '~', '-', '\\', '/' ] #Space is implied, characters forbidden by os filename limitations
    FILTER_CHARS = "\\/:*?<>|~-; "
     
    The source code is readable and simple enough to follow. I did try to read other metadata agents and couldn't understand a thing... so obscure...
    it search the exact title with no sustitution and with sustitution at the same time to parse only once for that.
    If that doesn't work, it replace filter chars with spaces and splits the words using split chars, remove the ones matching a lacklist and search the rest...
     
    If you know php or c++ or even c, you will e able to read the source code

    Absolute Series Scanner (ASS): Seasons+Absolute mode series scanner managing subdirectories and AniDB type specials,with a logging off all files (skipped on top of root folder, then sorted one line per file with regex used and info, all series sorted alphabetically) and one with the filelist to reproduce the library on my end with dummy files. It also add all files and recognise specials pretty accurately.

    http AniDB Metadata Agent (HAMA): Some good info there, will have to re-write it at some point... Data folders are kinda mandatory... Huge libraries can fetch 10gb in space. If you have no poster but other metadata is showing, create "Plug-in Support/Data/com.plexapp.agents.hama/DataItems" agent folders as indicated in the readme on GitHub

    Impressed by the agent recognition rate? Consider donating few euros through Paypal: Absolute Series Scanner + HTTP AniDB Metadata Agent. (Donators: xnaas, Sven-7, Niegen, Vorador, Fratal, T. Mayville,  A. Estremera, KJKingJ. Thanks guys)

  • MehdroidMehdroid Posts: 10Members, Plex Pass Plex Pass
    Mehdroid wrote on April 13 2014, 9:19 PM: »

    I will check it out now :) Thanks for the update

    ZeroQI wrote on April 13 2014, 8:58 AM: »

    Thanks Mehdroid! the other anidb agent use an account, file checksum, no posters, no episode summaries so of course this one is better :D

    I looked into "steins;gate" and other titles with a semi-colon, and i unfortunaltly cannot fix fully... as the title received by the agent is "Steins" if the search string is "Steins;gate", but i changed something so the keyword search can pick it up, just not a 100% match so has to be manually updated, but it picks it up without modifying anything. Good enough...

     K-On! and K-On!! and titles with years works ok now (changed agent to make a direct comparison without substitution and one with substitutions,  Key word search should pick it up if fails... so i need people to update their agent and test...  You can always use aid:xxxx with xxxx being the anidb id (at the end of the URL) for manual assignment shall any serie not be found (please feedback if that is the case)

    Created a list for missing episodes (same as other logs, in data folder where i keep a cache of the theme songs posters and fanart, Support added for specials. specials not in anidb gets their episode number as title (too much code rewrite to change that, would have to change from parsing the xml to parsing metadata scanned files, wouldn't be optimized)

    Support for OPs/EDs, trailers, etc.
    OPs/EDs "C": Season 0 Episodes 101-199 (e.g. anidb C1 => S00e101)

    Trailers "T": Season 0 Episodes 201-299 (anidb T1 => S00e201, T2 => s00e02, ...)
    Parodies "P": Season 0 Episodes 301-399  (anidb P1 => S00e301, P2 => s00e302, ...)
    Other "O": Season 0 Episodes 401-499     (anidb O1 => S00e401, O2 => s00e402, ...)

    Few Plex bugs: you need to change view while in serie season 0 to list new detected files, need to go on ep to refresh title.

    Should only affect refreshes, not the first detection

     

    Just replace __init__.py with the code on github

    Tests were done with a kanji folder name so seem to be pretty stable... Please feedback any issue or functionality wished...

    Please update the database using the logs, series without posters would have a link to update... Hold on few months for theme songs, plex team will update their backlog (oldest has been submited a year ago still not integrated)

    When using HAMA currently, do we need the S00 in the title for it to be recognized? 

    [Coalgirls]_Canaan_S00_ED_(1280x720_Blu-Ray_FLAC)_[3B12BB6F].mkv

    vs

    [Coalgirls]_Canaan_ED_(1280x720_Blu-Ray_FLAC)_[3B12BB6F].mkv

    So I am new to this, is their a naming convention besides OP, EP and OVA that need to be present in the filename for them to be correctly tagged by Hama?

  • ZeroQIZeroQI Posts: 1,225Members ✭✭✭

    There is more of a naming convention for plex, rather than for Hama specially (just a numbering shift per special type)

    See Plex official page about naming conventions: https://oldwiki.plexapp.com/index.php?title=Media_Naming_and_Organization_Guide#TV_Shows 

       . Multiple parts for a single ep: "cdX", "discX", "diskX", "dvdX", "partX", or "ptX"where the X is the digit so Heroes s01e01 - pt1.ext for example

       . Multiple episodes: /TV Shows/Heroes/Season 2/Heroes - s02e05-e08.mkv

       . Specials: /TV Shows/Heroes/Specials/Heroes - s00e02 - Countdown to Season 3.mkv. Specials are considered "Season 0" so you can name a folder that

       . You can forego Season 1 folder for anime

       . Using absolute numbering, all episodes are in season 1, but you can use thanks to BABS "tile 01.ext" format so no need for "Season 1" folder

       . Please note when renaming files, i had to change the view in the season page and click o nthe episode to refresh the title because of the case, but i was doing a lot of changes to test HAMA so it is the best agent for anime.

    However for specials, you need custom numbering, i could not get around it as Plex assigns episode numbers so could not name them as AniDB does, so used the same naming convention as the AniDB XBMC mod agent.

    So for example, for opening 1 in AniDB.net, name it: "Canaan s00e101.ext" although "Canaan s00e101 Opening [Coalgirls].ext" would probably work, but crcs and release group names in title make it sometimes difficult to get the episode number, especially if they have a date or number, although the scanner is good generally at sorting this out.

    Give fake episodes numbers if the data is not on AniDB, so if there is two openings there, and you have a third one, name it s00e103... They won't be scrapped, be will at least show...

    Absolute Series Scanner (ASS): Seasons+Absolute mode series scanner managing subdirectories and AniDB type specials,with a logging off all files (skipped on top of root folder, then sorted one line per file with regex used and info, all series sorted alphabetically) and one with the filelist to reproduce the library on my end with dummy files. It also add all files and recognise specials pretty accurately.

    http AniDB Metadata Agent (HAMA): Some good info there, will have to re-write it at some point... Data folders are kinda mandatory... Huge libraries can fetch 10gb in space. If you have no poster but other metadata is showing, create "Plug-in Support/Data/com.plexapp.agents.hama/DataItems" agent folders as indicated in the readme on GitHub

    Impressed by the agent recognition rate? Consider donating few euros through Paypal: Absolute Series Scanner + HTTP AniDB Metadata Agent. (Donators: xnaas, Sven-7, Niegen, Vorador, Fratal, T. Mayville,  A. Estremera, KJKingJ. Thanks guys)

  • jesmoresjesmores Posts: 9Members, Plex Pass

    Is there a way to find out what files are in my library that HAMA saw but did not recognize/process? I have this stubborn anime episode that is not showing up in Plex at all after doing a library update or even force refresh.

    D:\ServerFolders\Videos\Anime\Love Live! School Idol Project (2014)\[HorribleSubs] Love Live! S2 - 01 [720p].mkv

    • I'm running plex + hama on Windows Home Server 2011
    • I know the file hash at least exists in AniDB because it was recognized and automatically sorted by JMM Server, an external program I use to organize my library which also uses AniDB as backend.
    • There is no mention of this file in Plex's logs for the hama plugin
    • I manually downloaded the latest anime-titles.xml from anidb's site, and made sure it contained the title "Love Live! School Idol Project (2014)"
    • The version of hama I'm running is pulled from github as of April 10 I think. I'm not sure if I got the April 14 changes.
    • I also tried renaming the above file to [HorribleSubs] Love Live! School Idol Project (2014) - 01 [720p].mkv but still no luck

    After discovering this, I'm slightly concerned that there are shows in my library that aren't being shown in Plex at all, which is why I think an "Unrecognized Files" list somewhere would be great so I can address any naming / format issues that may have appeared in my library, and also help you debug any corner cases for filenames that explicitly fail the matching.

  • ZeroQIZeroQI Posts: 1,225Members ✭✭✭

    Jesmores, thanks for the suggestion, and documenting at the very least, that helps to answer in one go...

    No there isn't a way... (in Hama at least). Hama work after the scanner (please tell me you use BABS scanner and it is selected) on shows already detected by the scanner...Even if a show wasn't recognised by HAMA scraping process, it would still show as a file so if it isn't, it is the scanner fault, or rather... yours due to faulty naming... 

    The functionality suggested is nice however, cannot be implemented in the agent (but the scanner in the other hand ?might give it a try if i have no other functionality to add in the agent...). On a side note, i implemented a MISSING episodes log couple of days back...

    What you can do:

    0 . get rid of the crap in brackets before the filename, there's already a year in bracket in the title to confuse it

    1 . update have taking the latest code file on github, i updated a lot last week, including support of series with year in the title

    2 . name it Love Live! School Idol Project (2014)/Love Live! School Idol Project (2014) 01.mkv

    3 . if doesn't scan, name it Love Live! School Idol Project (2014)/Love Live! School Idol Project 01.mkv

     
    After checking, this title is the most ennoying to track, too many similar name animes...
    On top of that, there is a two week cache for series, and the episode air date is: 06.04.2014
    So once picked up by the scanner, do a manual search with "aid:9927" to be sure to pick the right one

    Actually there is a title missing on TVDB xml, so corrected a bug so update with the code i just saved on github...

    Absolute Series Scanner (ASS): Seasons+Absolute mode series scanner managing subdirectories and AniDB type specials,with a logging off all files (skipped on top of root folder, then sorted one line per file with regex used and info, all series sorted alphabetically) and one with the filelist to reproduce the library on my end with dummy files. It also add all files and recognise specials pretty accurately.

    http AniDB Metadata Agent (HAMA): Some good info there, will have to re-write it at some point... Data folders are kinda mandatory... Huge libraries can fetch 10gb in space. If you have no poster but other metadata is showing, create "Plug-in Support/Data/com.plexapp.agents.hama/DataItems" agent folders as indicated in the readme on GitHub

    Impressed by the agent recognition rate? Consider donating few euros through Paypal: Absolute Series Scanner + HTTP AniDB Metadata Agent. (Donators: xnaas, Sven-7, Niegen, Vorador, Fratal, T. Mayville,  A. Estremera, KJKingJ. Thanks guys)

  • MehdroidMehdroid Posts: 10Members, Plex Pass Plex Pass
    ZeroQI wrote on April 14 2014, 11:22 AM: »

    There is more of a naming convention for plex, rather than for Hama specially (just a numbering shift per special type)

    See Plex official page about naming conventions: https://oldwiki.plexapp.com/index.php?title=Media_Naming_and_Organization_Guide#TV_Shows 

       . Multiple parts for a single ep: "cdX", "discX", "diskX", "dvdX", "partX", or "ptX"where the X is the digit so Heroes s01e01 - pt1.ext for example

       . Multiple episodes: /TV Shows/Heroes/Season 2/Heroes - s02e05-e08.mkv

       . Specials: /TV Shows/Heroes/Specials/Heroes - s00e02 - Countdown to Season 3.mkv. Specials are considered "Season 0" so you can name a folder that

       . You can forego Season 1 folder for anime

       . Using absolute numbering, all episodes are in season 1, but you can use thanks to BABS "tile 01.ext" format so no need for "Season 1" folder

       . Please note when renaming files, i had to change the view in the season page and click o nthe episode to refresh the title because of the case, but i was doing a lot of changes to test HAMA so it is the best agent for anime.

    However for specials, you need custom numbering, i could not get around it as Plex assigns episode numbers so could not name them as AniDB does, so used the same naming convention as the AniDB XBMC mod agent.

    So for example, for opening 1 in AniDB.net, name it: "Canaan s00e101.ext" although "Canaan s00e101 Opening [Coalgirls].ext" would probably work, but crcs and release group names in title make it sometimes difficult to get the episode number, especially if they have a date or number, although the scanner is good generally at sorting this out.

    Give fake episodes numbers if the data is not on AniDB, so if there is two openings there, and you have a third one, name it s00e103... They won't be scrapped, be will at least show...

    Duly noted!Thank you for the explanation

  • jesmoresjesmores Posts: 9Members, Plex Pass
    ZeroQI wrote on April 14 2014, 10:02 PM: »

    Jesmores, thanks for the suggestion, and documenting at the very least, that helps to answer in one go...

    No there isn't a way... (in Hama at least). Hama work after the scanner (please tell me you use BABS scanner and it is selected) on shows already detected by the scanner...Even if a show wasn't recognised by HAMA scraping process, it would still show as a file so if it isn't, it is the scanner fault, or rather... yours due to faulty naming... 

    The functionality suggested is nice however, cannot be implemented in the agent (but the scanner in the other hand ?might give it a try if i have no other functionality to add in the agent...). On a side note, i implemented a MISSING episodes log couple of days back...

    What you can do:

    0 . get rid of the crap in brackets before the filename, there's already a year in bracket in the title to confuse it

    1 . update have taking the latest code file on github, i updated a lot last week, including support of series with year in the title

    2 . name it Love Live! School Idol Project (2014)/Love Live! School Idol Project (2014) 01.mkv

    3 . if doesn't scan, name it Love Live! School Idol Project (2014)/Love Live! School Idol Project 01.mkv

     
    After checking, this title is the most ennoying to track, too many similar name animes...
    On top of that, there is a two week cache for series, and the episode air date is: 06.04.2014
    So once picked up by the scanner, do a manual search with "aid:9927" to be sure to pick the right one

    Actually there is a title missing on TVDB xml, so corrected a bug so update with the code i just saved on github...

    Thanks for the quick response. I was already using BABS, but I did see there is a pretty recent update out which makes it recognize OP and ED, so I updated to that. I also updated to the very latest version of HAMA from GitHub.

    • I got a couple new entries from my existing library, probably due to a combination of both the BABS update and your fix for missing TVDB titles
    • Love Live S2 still wasn't recognized though :(
    • You make a good point about the brackets, but most of my files are in that format already, where the subber name comes first enclosed by square brackets, and it works for an overwhelming majority of the cases. As much as possible I want to avoid manual renaming of my files because my server is pretty much automated in organizing and indexing anime coming from RSS feeds (it's super-convenient when it works). It works until it doesn't work, in this case.
    • That said, I will try the rename as a last resort and see if that finally causes the file to be loaded into PLEX.
    • It sounds like the issue lies not with HAMA but with BABS, I know you're not the original developer, but do you know if there is a way to get log output from that scanner to show up somewhere so I can see what it's trying to do?
    • Barring that, what is the plex plugin API for sending output to one of the PLEX log files? I want to just edit the BABS.py file and add debug statements myself, but I have zero knowledge of the Plex API to be able to dig into this deeper
  • ZeroQIZeroQI Posts: 1,225Members ✭✭✭
    edited April 2014

    I can only add info on something detected, and detection is the scanner job alone. Is the file showing up in plex at all ?

    You can also just compare your file naming to the REGEX. the year in bracket might be the problematic part if the brackets don't cause issues on other anime...(possibly treating the year as ep number then failing at translating it)

     

    You can actually query the scanner from command line: https://plexapp.zendesk.com/hc/en-us/articles/201242707-Plex-Media-Scanner-via-Command-Line, and that where the print command will output i believe, but i prever the log to file method

     

    BABS location: /volume1/Plex/Library/Application Support/Plex Media Server/Scanners/Series/BABS.py

    Log location: /volume1/Plex/Library/Application Support/Plex Media Server/Logs/Plex Media Scanner.log

    The log show it scans anime, but i cannot see ANY BABS related log nor skipped files....

    I believe it's because there is no output to the log file in the source. The different output logs are: https://dev.plexapp.com/docs/api/logkit.html#module-Log . you might want to copy all "print" commands and add a debug one afterwards:

       . print "BABS: tlrs os.path.basename, i = |", i, "| file = |", file, "|" => Log.Debug ( "BABS: tlrs os.path.basename, i = |", i, "| file = |", file, "|" )

    [EDIT]

    i did create a test folder and Plex category as TV series using babs and HAMA with: _Jap test/Love Live! School Idol Project (2014)/[HorribleSubs] Love Live! S2 - 01 [720p].mkv with a random file, since there is no crc file check on HAMA, just filename.. i included the screen capture.

    I can see the serie and episode name so are you SURE the episode isn't picked up?

    note:

       . you need last night code otherwise the plugin crashed because the tvdb xml miss an anime title and anidb miss description for now

       . make sure to add the parent of the "Love Live! School Idol Project (2014)" folder ad Plex lookup folder (you can add multiples if you split your collection per first letter)

       . On latests versions you cannot force the XML file loaded locally, it downloads automatically, cache it in plex for two weeks, but copy it every time to the data folder [/volume1/Plex/Library/Application Support/Plex Media Server/Plug-in Support/Data/com.plexapp.agents.hama/DataItems/XMLs/anime-titles.xml].Knowing the file was aired less than two weeks ago, and since i can detect it,

    Absolute Series Scanner (ASS): Seasons+Absolute mode series scanner managing subdirectories and AniDB type specials,with a logging off all files (skipped on top of root folder, then sorted one line per file with regex used and info, all series sorted alphabetically) and one with the filelist to reproduce the library on my end with dummy files. It also add all files and recognise specials pretty accurately.

    http AniDB Metadata Agent (HAMA): Some good info there, will have to re-write it at some point... Data folders are kinda mandatory... Huge libraries can fetch 10gb in space. If you have no poster but other metadata is showing, create "Plug-in Support/Data/com.plexapp.agents.hama/DataItems" agent folders as indicated in the readme on GitHub

    Impressed by the agent recognition rate? Consider donating few euros through Paypal: Absolute Series Scanner + HTTP AniDB Metadata Agent. (Donators: xnaas, Sven-7, Niegen, Vorador, Fratal, T. Mayville,  A. Estremera, KJKingJ. Thanks guys)

  • jesmoresjesmores Posts: 9Members, Plex Pass

    HMMM the plot thickens ... it's possible the episode did get added to my Plex library, but ended up in the wrong show? It would show up as recently added episodes though, and I did not see it there. Doing a search for "Love Live" also doesn't show the new season (it's how I'm checking if it eventually got added, after every change I try to make).

    Is there a way to do a reverse lookup in Plex, where I search for a filename and it gives me which shows/episodes it got associated with by Plex?

    I'm pretty sure I have the most recent ver. of anime-titles.xml, I opened it yesterday and found the Love Live! School Idol Project (2014) title was included in it.

    Thanks so much for your suggestions so far - I need to go to bed now, but I will investigate this some more tomorrow.

  • ZeroQIZeroQI Posts: 1,225Members ✭✭✭
    edited April 2014

    If you look for the filename in the scanner log, otherwise try folder view in plex, maybe you can search a filename there

    Personally i would:

       . create a test folder

       . move the folder there

       . set up this test folder using babs and hama

       . see what happens, and it's easier to troubleshoot that way...

    I don't know which way to go now...

       . Perfect collections by using series listed in AniDB maping graph and using as title for collection the anime name with the lowest anidbid...

       . local cache for anidb serie xml file, to check locally first and load from web if ep title missing but cache it? 

       . use fanart.tv API do download additional posters http://fanart.tv/api-docs/tv-api/ and https://github.com/plexinc-agents/Fanart-TV.bundle/tree/master/Contents

       . "anidb.id" file icontaining the anidbid in serie root folder (or Specials) to be used as anime id with no prompt - code in ReadNFO [https://github.com/ndevenish/Plex-ReadNFO/blob/master/Contents/Code/__init__.py] would allow to implement quickly 

    Do any of you use another anime plugin (myanimelist or anidb metadata agent)? If so what is lacking in HAMA?

    What functionalities do you all wish for first or think is the most useful ? Fell free to add to the above list

    Absolute Series Scanner (ASS): Seasons+Absolute mode series scanner managing subdirectories and AniDB type specials,with a logging off all files (skipped on top of root folder, then sorted one line per file with regex used and info, all series sorted alphabetically) and one with the filelist to reproduce the library on my end with dummy files. It also add all files and recognise specials pretty accurately.

    http AniDB Metadata Agent (HAMA): Some good info there, will have to re-write it at some point... Data folders are kinda mandatory... Huge libraries can fetch 10gb in space. If you have no poster but other metadata is showing, create "Plug-in Support/Data/com.plexapp.agents.hama/DataItems" agent folders as indicated in the readme on GitHub

    Impressed by the agent recognition rate? Consider donating few euros through Paypal: Absolute Series Scanner + HTTP AniDB Metadata Agent. (Donators: xnaas, Sven-7, Niegen, Vorador, Fratal, T. Mayville,  A. Estremera, KJKingJ. Thanks guys)

  • SnivesSnives Posts: 16Members, Plex Pass Plex Pass
    ZeroQI wrote on April 15 2014, 12:45 PM: »

    If you look for the filename in the scanner log, otherwise try folder view in plex, maybe you can search a filename there

    Personally i would:

       . create a test folder

       . move the folder there

       . set up this test folder using babs and hama

       . see what happens, and it's easier to troubleshoot that way...

    I don't know which way to go now...

       . Perfect collections by using series listed in AniDB maping graph and using as title for collection the anime name with the lowest anidbid...

       . local cache for anidb serie xml file, to check locally first and load from web if ep title missing but cache it? 

       . use fanart.tv API do download additional posters http://fanart.tv/api-docs/tv-api/ and https://github.com/plexinc-agents/Fanart-TV.bundle/tree/master/Contents

       . "anidb.id" file icontaining the anidbid in serie root folder (or Specials) to be used as anime id with no prompt - code in ReadNFO [https://github.com/ndevenish/Plex-ReadNFO/blob/master/Contents/Code/__init__.py] would allow to implement quickly 

    Do any of you use another anime plugin (myanimelist or anidb metadata agent)? If so what is lacking in HAMA?

    What functionalities do you all wish for first or think is the most useful ? Fell free to add to the above list

    My only issue I've had is Hunter X Hunter (2011) keep getting recognized as Hunter X Hunter (1999).

    Structure is #Library#\Hunter X Hunter (2011)\Hunter X Hunter - {Abs EP. No.} [480p]

    When telling it to attempt to fix mismatch, Hunter X Hunter (1999) is also the only result that comes back. I have to advanced search -> change date to 2011 and search again to find it. I haven't tried inserting (2011) into the file name yet, but with my setup that would be just as tedious as merging the two folders whenever I see a split start again. Not a big issue, and likely isolated to this show, but thought I'd point it out.

  • lvulliermetlvulliermet Posts: 11Members, Plex Pass Plex Pass

    Hi there !

    Seems great and look forward having finish building my server (currently setting it up).

    Does your HAMA manage to split the seasons too from a single folder with all the files as absolute numering?

    (meaning would it split the seasons and get the according covers as illustrated here https://forums.plex.tv/topic/31081-better-absolute-scanner-babs/page-2#entry632479)

    Or shall I try to use it with S BSB too?

  • ZeroQIZeroQI Posts: 1,225Members ✭✭✭

    @Snives:  for me when searching "Hunter x Hunter" it only finds the 1999 one, but searching "Hunter x Hunter (2011)" it finds it ok.

    you can also override with aid:8550 in the search title (http://anidb.net/perl-bin/animedb.pl?show=anime&aid=8550 for hunter x hunter (2011))

    @:the scanner job is to take the file name and decode which season and episode number it belongs to.

    the metadata agent job is to update data for the detected files

    Anidb uses absolute numbering

    S-BABS scanner would move the seasons and episode number around and i would have no easy way to map this

    If you like seasons, please use the tvdb agent.

    @All: since the last couple weeks, Plex was updated on my Synology NAS, and the web links are now working to ANIDB, TVDB and ANN. i have added on git a mod to display a link to the relation graph "(#)" after anidb link in serie description

    Absolute Series Scanner (ASS): Seasons+Absolute mode series scanner managing subdirectories and AniDB type specials,with a logging off all files (skipped on top of root folder, then sorted one line per file with regex used and info, all series sorted alphabetically) and one with the filelist to reproduce the library on my end with dummy files. It also add all files and recognise specials pretty accurately.

    http AniDB Metadata Agent (HAMA): Some good info there, will have to re-write it at some point... Data folders are kinda mandatory... Huge libraries can fetch 10gb in space. If you have no poster but other metadata is showing, create "Plug-in Support/Data/com.plexapp.agents.hama/DataItems" agent folders as indicated in the readme on GitHub

    Impressed by the agent recognition rate? Consider donating few euros through Paypal: Absolute Series Scanner + HTTP AniDB Metadata Agent. (Donators: xnaas, Sven-7, Niegen, Vorador, Fratal, T. Mayville,  A. Estremera, KJKingJ. Thanks guys)

Sign In or Register to comment.