INTERACT FORUM

Please login or register.

Login with username, password and session length
Advanced search  
Pages: [1]   Go Down

Author Topic: How to always import videos with folder name as name for the video?  (Read 6442 times)

8139david

  • Galactic Citizen
  • ****
  • Posts: 345

I want to import many videos of different types: .mkv, .avi, .m2ts, iso, video_ts folders, bluray folders.
The movies from video_ts folders are assigned as name the name of the folder containing video_ts.
I would like this to be always the case, ie also when I import a folder containing a mkv, avi or m2ts file.
(Indeed, all my folders contain the information which is important to me, eg:
Author_name Firstname - Year - Title - Filetype)
But currently, it doesn't do it.
For instance, for single m2ts files, it assigns as name the name of the file (eg. 00000.m2ts).
Likewise for iso.
And for mkv, it seems to use tagging information inside the mkv.
What can I do?
Logged

blgentry

  • Regular Member
  • Citizen of the Universe
  • *****
  • Posts: 8014
Re: How to always import videos with folder name as name for the video?
« Reply #1 on: January 14, 2016, 10:16:08 am »

In your auto import setup, you probably have a separate directory for videos set up.  If you don't you'll probably need to do so.  You can edit the definition of this auto import directory and then use "apply these tags" (at the bottom).  Choose custom and do something like:

[Name] = filefolder()

Filefolder returns the first directory up from the file in question, so that should work correctly.  You can make filefolder() go further up the path if you need it to.  Docs:

http://wiki.jriver.com/index.php/Expression_Language#FileFolder.28.E2.80.A6.29:_Returns_the_name_of_a_file.27s_parent

As for metadata in the MKVs I haven't had any issue with this.  MC always runs "get movie and tv info" on the videos I import and fills in the metadata from the various databases.  You can run this manually if you need to by right clicking the file and choosing "get movie and TV info".  That should get everything automatically.

Brian.
Logged

8139david

  • Galactic Citizen
  • ****
  • Posts: 345
Re: How to always import videos with folder name as name for the video?
« Reply #2 on: January 14, 2016, 11:45:14 am »

Thanks!

I did it, but then I have this problem:
- For dvds (ie ifo files), I should ask for the grandparent folder.
- For the other files (mkv, m2ts, iso, avi), I should ask for the parent.
Is there anyway to specify that?
Logged

blgentry

  • Regular Member
  • Citizen of the Universe
  • *****
  • Posts: 8014
Re: How to always import videos with folder name as name for the video?
« Reply #3 on: January 14, 2016, 12:02:30 pm »

You can have two different auto import folders with two different rules.  Or you could construct a custom rule that uses an if statement that compares the file types and uses one expression for DVD (ifo) files and another expression for everything else.

Brian.
Logged

8139david

  • Galactic Citizen
  • ****
  • Posts: 345
Re: How to always import videos with folder name as name for the video?
« Reply #4 on: January 14, 2016, 12:05:05 pm »

Thanks, that's what I was beginning to realize.
There should be a way, since there is an If() function and an IfElse() function.
But I have also other cases as well.

So all in all, it is simpler to just import the movie when I want to see it.
And simply navigate through my video folders externally, as I am used to do.
Logged

astromo

  • MC Beta Team
  • Citizen of the Universe
  • *****
  • Posts: 2251
Re: How to always import videos with folder name as name for the video?
« Reply #5 on: January 14, 2016, 12:05:52 pm »

And for mkv, it seems to use tagging information inside the mkv.
What can I do?

As an aside, the latest offering of mkvtoolnix offers header editing functionality. A real plus because this avoids having re-mux a vid file if you want to tidy up odds and ends.
Logged
MC33, Win10 x64, HD-Plex H5 Gen2 Case, HD-Plex 400W Hi-Fi DC-ATX / AC-DC PSU, Gigabyte Z370 ULTRA Gaming 2.0 MoBo, Intel Core i7 8700 CPU, 4x8GB GSkill DDR4 RAM, Schiit Modi Multibit DAC, Freya Pre, Nelson Pass Aleph J DIY Clone, Ascension Timberwolf 8893BSRTL Speakers, BJC 5T00UP cables, DVB-T Tuner HDHR5-4DT

blgentry

  • Regular Member
  • Citizen of the Universe
  • *****
  • Posts: 8014
Re: How to always import videos with folder name as name for the video?
« Reply #6 on: January 14, 2016, 12:15:00 pm »

Thanks, that's what I was beginning to realize.
There should be a way, since there is an If() function and an IfElse() function.
But I have also other cases as well.

If you can define the cases, you can probably code a rule to tag your files on import as you expect.  Or you can just do it in a batch and be done with it.  You could set up a view that showed you files by folder and allowed you to apply the appropriate filefolder rule to sets of files.  In fact, you could create columns in a view that showed parent, grand parent, great grand parent, etc, and then select groups of files and apply those as [Name] field.

How many videos are we talking about here?

Quote
So all in all, it is simpler to just import the movie when I want to see it.
And simply navigate through my video folders externally, as I am used to do.

I see so many people with the attitude of "my file system is just easier" and it blows my mind.  With a little extra work, you can have all of the metadata correctly filled out and a much richer experience of browsing your collection.  I suppose if you're perfectly happy with the file system, and you've been doing it for years, and there NOTHING you can get from metadata... then be happy with the file system.  But I think you're missing out.

Brian.
Logged

ferday

  • MC Beta Team
  • Citizen of the Universe
  • *****
  • Posts: 1732
Re: How to always import videos with folder name as name for the video?
« Reply #7 on: January 14, 2016, 12:32:21 pm »

blgentry is right, not to mention...by using MC to tag the metadata, then using the brilliant RMC tool, you can have both the metadata and a beautiful on-disk folder organization, all in one shot!
Logged

8139david

  • Galactic Citizen
  • ****
  • Posts: 345
Re: How to always import videos with folder name as name for the video?
« Reply #8 on: January 14, 2016, 01:07:09 pm »

Thanks for your remarks. I'll look into that again.

Potentially, I could have 2000 movies or so to tag.

Two years ago, I did the work on an Excel file, adding the fields I was interested in.
But now I have even more movies. So I don't want to tag anymore, except for finding this information:
Author_Name FirstName - Year - Title - FileFormat

PS: I did a small experiment with automatic lookup from JRiver, with one folder on a hard drive. All the information was wrong.

PPS: For some reason, I'm happy to do the work for my music, tagging it with mp3tag or foobar2000.
For films, I just feel (personnally) it's a waste of time.


Logged

JimH

  • Administrator
  • Citizen of the Universe
  • *****
  • Posts: 72548
  • Where did I put my teeth?
Re: How to always import videos with folder name as name for the video?
« Reply #9 on: January 14, 2016, 01:17:51 pm »

If you have a lot of videos, it would be worth reading and understanding this:
http://wiki.jriver.com/index.php/Carnac
Logged

blgentry

  • Regular Member
  • Citizen of the Universe
  • *****
  • Posts: 8014
Re: How to always import videos with folder name as name for the video?
« Reply #10 on: January 14, 2016, 03:13:03 pm »

Potentially, I could have 2000 movies or so to tag.

Ok, pretty big number.  With the right method, you could probably get this done in a couple of hours.  But I'd need to see some of your file structure to be sure.

Quote
Two years ago, I did the work on an Excel file, adding the fields I was interested in.
But now I have even more movies. So I don't want to tag anymore, except for finding this information:
Author_Name FirstName - Year - Title - FileFormat

Title makes sense in terms of movies.  So does year.  I'm not sure about the rest.  Is this a generic list, or do you have some value you want to assign to Author_Name and FirstName for a movie?

Quote
PS: I did a small experiment with automatic lookup from JRiver, with one folder on a hard drive. All the information was wrong.

Without more information, I can't help you.

Quote
PPS: For some reason, I'm happy to do the work for my music, tagging it with mp3tag or foobar2000.
For films, I just feel (personnally) it's a waste of time.

I'm trying to help, but you don't seem to want to proceed.  I'm here if you want to.  Otherwise, I hope you enjoy MC.

Brian.
Logged

8139david

  • Galactic Citizen
  • ****
  • Posts: 345
Re: How to always import videos with folder name as name for the video?
« Reply #11 on: January 14, 2016, 03:57:00 pm »

Thanks for your help!

By AuthorName, I mean DirectorName. (FirstName is then the director's first name.)
And for me, this is a very important information!
I value directors a lot, look for and collect other movies by the same director, etc.
When you have several hundreds of movies, or more, it's very handy to have say, 5 movies by Chaplin named according to my scheme.

(Potentially, I would also be interested with any information about the movie if I could easily get reliable information.)

Typically the file structure is simple.
Winthin a folder for videos, I have any of these:
FolderName > File [mkv, m2ts, avi, iso]
FolderName > Video_ts > Files [= full dvd structure]
FolderName > [full bluray structure]
In each case, FolderName = AuthorName FirstName - Year - FilmTitle - FileType
But for a few boxsets (my bad), I have an additional level:
FolderName > Subfolder1, Subfolder2, etc, with Subfolder1 > Video_ts > File, Subfolder2 > Video_ts, etc
Logged

blgentry

  • Regular Member
  • Citizen of the Universe
  • *****
  • Posts: 8014
Re: How to always import videos with folder name as name for the video?
« Reply #12 on: January 14, 2016, 04:33:16 pm »

(Potentially, I would also be interested with any information about the movie, but only if I could easily get reliable information.)

Director is a nice piece of information to have.  In fact, having this information has given me visibility into my collection that I didn't have before.  Staring at a rack full of DVDs, you don't get to immediately see director, actors, etc.  With MC, you do!

You should try filling in the correct name, manually, for a few of your movies.  Then highlight them and do "get movie and TV info".  See what information is populated.  For the vast majority of mine, I get director, actors, summary, keywords, genre, etc.

How reliable is this?  I'd say something like 90 to 95% were correct first time.  Perhaps more.  If you end up with 90% reliable, that would mean almost 200 to correct, which is a lot.  I'd suggest doing the lookups in batches, so you make sure they are right.  If nothing else, the cover art will normally show you if the information is wrong.  Assuming you don't have duplicate film names like "The Italian Job" from both 1969 and 2003.

Quote
Typically the file structure is simple.
Winthin a folder for videos, I have any of these:
FolderName > File [mkv, m2ts, avi, iso]
FolderName > Video_ts > Files [= full dvd structure]
FolderName > [full bluray structure]
In each case, FolderName = AuthorName FirstName - Year - FilmTitle - FileType
But for a few boxsets (my bad), I have an additional level:
FolderName > Subfolder1, Subfolder2, etc, with Subfolder1 > Video_ts > File, Subfolder2 > Video_ts, etc

Here's what I personally would do:

1.  Add a new field to MC called something like "Title Approved".  Make it an Integer data type with an Edit type of check (that's a checkbox field).
2.  For every movie that's already imported and has the correct information, highlight those movies and put a check in "title approved".
3.  Make a new view that shows the movie name ( [Name] field), Title Approved, and several levels of the directory structure.  I'd also include the [filename] since it will have everything in it.
A.  To make these "levels", you just use an expression column with a value like:  filefolder(,1) .  That one shows the grandparent.  The great grandparent is filefolder(,2) .  Etc.  I'd show at least 3 if not 4 levels of this.
4.  Now, sort by each of these levels in turn.  You're going to see right away that a bunch of them will group together.  For example if you are sorting by level 3, then level 2 might have the Movie Title in it.  Play with the sorting and huge groups will jump out at you.
A.  At this point, you highlight everything that is sorting so that a certain level has the movie name.  Then copy the expression from that column (or just type it) and paste it into the [Name] field for those selected movies.  You do this through the tagging window, so you'll do all of them at once.
B.  Once you've changed their names, check them to make sure they are correct.  If you find any that are wrong, deselect them.
C.  You saw this coming right?  Now that all of the highlighted files have titles that make sense, click the checkbox for "title approved".
5.  In your view, you should include a Pane up top for Title Approved.  Now you can hide everything that's approved by clicking in the Title Approved Pane and selecting only ones that are NOT approved.
6.  Repeat 4 - 5 above, sorting on different columns to group big chunks together.  After 2, 3, 4 rounds, you'll probably have 95 to 99% of  your titles done.
7.  Now clean up what's left by figuring out what part of the folder structure contains the name.  Again, use the tagging pane to paste in an expression for the proper level of the directory structure that has the name.

Once all of that is done, I'd do "get movie and TV info" in groups of some size that's manageable.  You might also include an additional MC field called "tag approved" or something like that, so you can sort out the ones you've already done a lookup on and decided they are correct.

This ability to filter out the work you've already done is very powerful and makes the job go much faster.

When you're totally done, you're going to have a really awesome view into your collection with great cover art and lots of metadata.

Brian.
Logged

8139david

  • Galactic Citizen
  • ****
  • Posts: 345
Re: How to always import videos with folder name as name for the video?
« Reply #13 on: January 14, 2016, 04:48:31 pm »

Many thanks for the detailed advice, Brian!
I will try that!
Logged
Pages: [1]   Go Up