Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

i need some help #35

Closed
ste2w opened this issue Apr 13, 2023 · 27 comments
Closed

i need some help #35

ste2w opened this issue Apr 13, 2023 · 27 comments

Comments

@ste2w
Copy link

ste2w commented Apr 13, 2023

hey so i found this project last night and i got tvrename compiled but it kept throwing errors about vobsub2srt ( im on windows 10) i could not for the life of me figure out how to get vobsub2srt to work.. is there a way to getting vobsub2srt to work on windows? or should i try to build this in a linux virtual machine? im really confused id appreciate some help
Thanks! :)

@jasongdove
Copy link
Owner

Yeah, the dependencies are kind of nuts - I only ever run it in docker since the dependencies are bundled. Are you able to run linux docker images on your Windows machine?

@ste2w
Copy link
Author

ste2w commented Apr 13, 2023

honestly ive tried docker and i understand nothing of it i tried to set up one of those automatic rippers (automatic ripping machine) and i just for the life of me get anything in docker to run on my system lol i have no clue how to use it ive even tried plex in docker and couldnt get that working either but id definitely try again :) but im getting everything set back up and ill come back when i have docker installed and ill try it again id appreciate some pointers :)

EDIT ok so i got it building from the .zip i downloaded from here when its done how do i run it?? is it like this?

"docker --run tvrename rename "Path/to/tvshow/seasonXX"

"docker --run tvrename verify "Path/to/tvshow/seasonXX"

Sorry for the mass changes im just trying to learn all this stuff :)

@ste2w
Copy link
Author

ste2w commented Apr 13, 2023

so i got it installed.. (I think) but when it loaded the name was none and it had like 138 vulnerabilities and when i tried adding a path to point the container where to go it gave me this error

Failed to run image. Error invoking remote method 'docker-run-container': Error: (HTTP code 400) unexpected - invalid reference format

im really confused it was goin so well lol

EDIT my computer just bsod on me so I'm goin to reinstall windows and start with a clean slate maybe that will make it easier xD

@jasongdove
Copy link
Owner

@ste2w
Copy link
Author

ste2w commented Apr 13, 2023

so i found your docker container on docker and im pulling now...so because im on windows 10 how do i point it to the folder to run? how does all that work do i have to add my files to the docker container itself or do i have to point to a folder on my windows 10 computer?

@jasongdove
Copy link
Owner

I run it from linux, but the syntax is something like this

docker run --rm -v "/media/folder:/media/folder:rw" -v tvrenamecache:/cache jasongdove/tvrename:develop rename --imdb 1122334 "/media/folder/show name/season 01" --dry-run

You should only need to modify the /media/folder paths to point it to where your media lives, and find the appropriate imdb id instead of 1122334. If it looks like its going to rename things correctly, then you can remove --dry-run from the end.

@ste2w
Copy link
Author

ste2w commented Apr 13, 2023

ok so i found said filesystem in subsystem for linux but it wont let me transfer any test files over it says i need permission yet im literally the only user on this computer any idea on what i should do??

@jasongdove
Copy link
Owner

I don't think you need to run the docker command from wsl - it should also work in powershell or a command prompt using normal windows paths.

@ste2w
Copy link
Author

ste2w commented Apr 13, 2023

So I want to make sure I understand then so in docker where would I put my windows file path to the folder? Or do I have to move my folder with my files INTO the media folder in my Ubuntu subsystem?

@ste2w
Copy link
Author

ste2w commented Apr 13, 2023

C:\Users\MOVIE_ROOM>docker run -t jasongdove/tvrename:develop rename --imdb ######## "D:\tv__show\Path\to\tvshow\season_1"

i get this (Running from windows command prompt)

chown: cannot access '/cache': No such file or directory
groupmod: invalid group ID ''
usermod: invalid user ID ''
[22:08:39 FTL] Folder /app/D:\tv__show\path\to\tvshow\season_1 must be a directory

any ideas i have never gotten this far lol

And if I add a --mount before the path it's unrecognized

@ste2w
Copy link
Author

ste2w commented Apr 13, 2023

ok so i re read what you had post and to replace the /media/folder and i did which looked like this

docker run --rm -v D:\tv__show\tvshow\season_1:D:\tv__show\tvshow\season_1:rw -v tvrenamecache:/cache jasongdove/tvrename:develop rename --imdb ######### "D:\tv__show\tvshow\season_1"

it gave me this

docker: Error response from daemon: mount denied:
the source path "D:\tv__show\tvshow\season_1:D:\tv__show\tvshow\season_1:rw"
too many colons.
See 'docker run --help'.

@jasongdove
Copy link
Owner

Yeah it's definitely more complicated mixing windows and Linux paths. I'll test on windows in a bit and give a working example command.

@ste2w
Copy link
Author

ste2w commented Apr 13, 2023

thank you id appreciate it im down to try anything at this point lol its just a matter of trial and error haha!

@jasongdove
Copy link
Owner

Okay, this is kind of a mess on Windows, but I think I have it working.

First, you will want to run it from your WSL distro, not from cmd/powershell. So you will need to copy your media over. In this example I will use The Office (2005) Season 01:

mkdir /tmp/tv
cd /tmp/tv
cp -r /mnt/c/Media/Shows/The\ Office\ \(2005\) .
cd The\ Office\ \(2005\)/Season\ 01/
docker run -it --rm -e PUID=1000 -e PGID=1000 -v "/tmp/tv:/tmp/tv:rw" -v tvrenamecache:/cache jasongdove/tvrename:develop rename --imdb 0386676 "$(pwd)" --dry-run

A couple important points about the commands:

  • They all depend on a working root folder of /tmp/tv
  • You must cd into the Show/Season folder before running the docker command
  • The docker command will not need to be modified for different shows/seasons, since it uses $(pwd) which gets the current directory name

Hopefully that finally gets things going for you.

@ste2w
Copy link
Author

ste2w commented Apr 14, 2023

ok so i did some test and im still getting this error when i run the docker command

"Folder /tmp/Media/Shows/The Office (2005) must be a directory"

since i for some reason cant add anything in the /mnt/c folder im the only account since im the one who set it up that confused me a bit but anyway so i moved it in the only folder i had access to /tmp/ and it still doesnt think its a directory and i copy and pasted exactly what you typed with the exception of /mnt/c/ since i cant use that one

EDIT so i was able to cd into the season 01 folder by removing the space and doin an underscore yet it still tells me that it "Must be a directory"

@jasongdove
Copy link
Owner

You won't be able to add anything to /mnt/c as that's your C drive and linux seems to have issues writing to the Windows filesystem. I guess you're also using D, so it would be /mnt/d. Let me try to adjust the commands to what it might look like on your system based on your previous post:

mkdir /tmp/tv # do not change this line
cd /tmp/tv # do not change this line
cp -r /mnt/d/tv__show/tvshow . # this copies media from windows (d drive) to linux (under /tmp/tv)
cd tvshow/season_1
docker run -it --rm -e PUID=1000 -e PGID=1000 -v "/tmp/tv:/tmp/tv:rw" -v tvrenamecache:/cache jasongdove/tvrename:develop rename --imdb 0386676 "$(pwd)" --dry-run

The only thing you should have to change in the docker line is the imdb id.

@ste2w
Copy link
Author

ste2w commented Apr 14, 2023

OH ok yeah that makes sense so when i do the 3 line

cp -r /mnt/d/tv__show/tvshow
it gives me this error
cp: missing destination file operand after '/mnt/d/tv__show/evrybdy_lives_ray'

i had to remove some letters but thats what it tells me when i do the full name

@jasongdove
Copy link
Owner

There's a period at the end of the command which means the current directory.

cp -r /mnt/d/tv__show/tvshow .

@ste2w
Copy link
Author

ste2w commented Apr 14, 2023

ok so i got it running! however it says
test 1 match failed confidence 31 is too low
test 2 match failed confidence 33 is too low
test 3 match failed confidence 33 is too low
rest 4 match failed confidence 33 is too low

@jasongdove
Copy link
Owner

You can lower the required confidence by adding --confidence 30 to the command (for example).

@ste2w
Copy link
Author

ste2w commented Apr 14, 2023

ok cool that worked so where do i find the renamed files??

@jasongdove
Copy link
Owner

Remove --dry-run from the command if you want it to rename the files. Then you'll need to copy them back to windows. You may be able to open \\wsl$\Ubuntu in explorer, otherwise you will have to cd back into /mnt/d/whatever and copy the /tmp/tv files back that way.

@ste2w
Copy link
Author

ste2w commented Apr 14, 2023

ok that about solves it thank you so much for your patience lol i did learn alot though lol and also one last question before i close does this work on episodes that are out of order like say title01 is episode 3 title07 is episode 2 type of situation will it fix that too?? also what about tv show discs that dont have subtitles will this also work?? just wondering :)

@jasongdove
Copy link
Owner

Yes, the original filenames are irrelevant, it uses subtitles or (to address your second question) speech-to-text. I haven't used STT in a while, but it should work in the docker container for items that don't have subtitles. Note that this all assumes that open subtitles contains correct reference subtitles for comparison. If not, and you can find subtitles somewhere else, you can add them to the .tvrename/reference folder.

@ste2w
Copy link
Author

ste2w commented Apr 17, 2023

So I've been running it over the weekend and this thing is amazing lol but I had another question Cause I ended up having to redo a few seasons and it said the file already existed so should I be clearing the cache folder after I'm done everytime?? And I have found that when I use the dvd srts (instead of 720p or 1080p) from subscene I started hitting confidences of 100 to so is open subtitles just using the wrong versions Like trying to match the hd version with the sd version and im thinkin the frame sync is different to some degree but I figured it wouldn't matter all much since its the same show just different format is that even possible?? Sorry if that was confusing lol

@ste2w ste2w closed this as completed Apr 19, 2023
@jasongdove
Copy link
Owner

should I be clearing the cache folder after I'm done everytime

No - the cache stores the extracted/generated subtitles for each processed video file. There won't ever be a conflict there, even if you have different versions of the same episode.

And I have found that when I use the dvd srts (instead of 720p or 1080p) from subscene I started hitting confidences of 100 to so is open subtitles just using the wrong versions Like trying to match the hd version with the sd version and im thinkin the frame sync is different to some degree but I figured it wouldn't matter all much since its the same show just different format is that even possible

I don't know where OpenSubtitles sources its subtitles. This project doesn't care about subtitle timing, it only looks at text. If you are getting 100% confidence, then someone likely uploaded subtitles from similar source material.

@ste2w
Copy link
Author

ste2w commented Apr 19, 2023

Oh ok good to know! thank you for all your help I decided to close but hope ya have an awesome day man take care :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants