Looking for a bit more info on how videos are handled

I'm just testing out immich now hoping I can make it work for my use case. For right now I'm just trying to get some info on how the videos are handled. What is purpose of the encoded_videos folder? Is that like a temp folder where videos go before they are transcoded? Is there anyway to keep an original version of the video in the app as well as a transcoded version for viewing?
25 Replies
sogan
sogan2y ago
Hi! The encoded_videos folder is where transcoded videos are stored. Transcodes are used for viewing on web and mobile, but we always keep the originals untouched. You can also customize the policy for which videos get transcoded in the admin settings. If a video isn’t transcoded, the original is shown for viewing.
sizzleweet
sizzleweetOP2y ago
so in the main images folder, that's where the original files are stored?
sogan
sogan2y ago
yep, we store original photos and videos in the library folder and then upload is where uploaded files are temporarily stored until they're migrated to the right folder. thumbs stores generated images (small thumbnails, medium-size preview images and thumbhashes that are shown as placeholders until a thumbnail loads).
sizzleweet
sizzleweetOP2y ago
Ok, so when you access the file via the web browser you'll see the "encoded_video", but when you click download, you'll get the full quality video?
jrasm91
jrasm912y ago
Yup. You also might get the original in the web browser depending on what codec the video is using and what settings you have set regarding transcode options.
sizzleweet
sizzleweetOP2y ago
ok cool. That makes sense. So I can change my transcode version back to something reasonable lol I have it set to original, but that's not necessary as originals are maintained do the transocode settings apply to live photos as well?
jrasm91
jrasm912y ago
Oh yeah lol Yes, they apply to live photos as well.
sizzleweet
sizzleweetOP2y ago
and those are stored right alongside the original file, i.e. IMG_01010.JPG/HEIC & IMG_01010.mov
jrasm91
jrasm912y ago
So we are talking about originals vs generated content. Originals include both parts of live photos, which are named like this, yes: - IMG_01010.JPG - IMG_01010.mov
sizzleweet
sizzleweetOP2y ago
originals
jrasm91
jrasm912y ago
IMG_01010.mov is an "original" and will have an associated file in encoded_video/id.mov if it needs to be transcoded based on the settings, etc. All originals are in library/. And all of those originals will have two thumbnails in thumbs/. And some of the originals (that are videos) will have an encoded video in encoded_videos/.
sizzleweet
sizzleweetOP2y ago
gotcha, just making sure I understand things properly for testing this external folders PR, as I plan to use an app called photosync to get my files off my phone and into the "external" folder. It does the same thing with live photos it stores them alongside photos with the exact same name
jrasm91
jrasm912y ago
Naming them like that isn't actually how we detect they are live photos though. That is a separate process.
sizzleweet
sizzleweetOP2y ago
hmm gotcha, I'll have to see how it reacts to my current setup working on getting that pr build installed now
jrasm91
jrasm912y ago
Once they are in the external folder are you going to get them into immich using the library PR?
sizzleweet
sizzleweetOP2y ago
Yep, I'm going to see how that works yeah I haven't setup the docker container with that version yet though
jrasm91
jrasm912y ago
Got it.
sizzleweet
sizzleweetOP2y ago
I was using martabel's CA docker image, and am now switching to a docker compose build
jrasm91
jrasm912y ago
For that, the files should be scanned/read, and it should still generate the same generated content (thumbs, encoded videos, etc.), which will always end up in their respective folders. In both situations originals are kept and generated content is added (especially regarding transcoded videos).
sizzleweet
sizzleweetOP2y ago
alrighty. I'll let someone know how it goes 😄
sizzleweet
sizzleweetOP2y ago
Hey @jrasm91 since I've got your ear, you had mentioned the PR tag, would that go into the env file on docker compose?
jrasm91
jrasm912y ago
Ultimately you need the image to use the target tag
sizzleweet
sizzleweetOP2y ago
yep, I think I got it I added it in the env file instead of release I just put pr-3124
jrasm91
jrasm912y ago
Yup, this env IMMICH_VERSION is used in the compose file everywhere and defaults to release

Did you find this page helpful?