Move files to new drive, how to perserve categories.

Ask for help and post your question on how to use XnView MP.

Moderators: XnTriq, xnview

LordB
Posts: 6
Joined: Sat Aug 17, 2019 3:55 pm

Move files to new drive, how to perserve categories.

Post by LordB »

OK. I've struggled with categories in XnView MP in the past. So I'll ask for clarification before I do anything.

I am moving a folder full of images over a ethernet network connect from CPU #1 to CPU #2, with a M.2 ssd for faster loading and better performance. This folder contains around 40,000 images, 99% of them have been painstakingly stored into extensive categories over the last 4 years. Can someone please give me a step by step on how I can move this folder to the new computer without destroying the category system. Does XnView MP support moving files over a network? Is there another forum post with the answer? I know there's a move folder function within MP, but I am not sure on how to do this between two computers.

I think my current categories are messed up in a way. I previously moved folders without using XnView MP after I had some hard drive issues, and MP would not allow me to change the categories "the images are in this place over here" system after the fact. Even when using the move images function, the program did not recognize the new location because the old location no longer existed. I had to resort to recreating a empty folder in the original location so that it mimicked the location XnView MP used to look for the images so that the categories would work, and just placing all the images in the recreated folder totally separate from my other images folder. This worked, but I've not been able to move them since, which is annoying since I was unable to move them to any newer drives I obtained in the years since. But I left alone until now.

Any information would be appreciated.
User avatar
michel038
Posts: 786
Joined: Tue Sep 27, 2016 8:18 am
Location: France

Re: Move files to new drive, how to perserve categories.

Post by michel038 »

First, make some backups by copying your xnview.db file when XnViewMp is closed.

My own way was to enable export options (Tools, settings, Metadata, Export categories to xmp and iptc keywords ) before categorizing JPG photos.
This way, when you move the photos, you carry the keywords at the same time, and there is much less risk of losing information.
And in the new PC, import the keywords to categories.

If your categories are not mirrored into keywords, it's a bit more difficult.
A) You can choose to export them now, two methods
1- Enable export to iptc or xmp or both, Display lots of JPG photos in the browser with "view files in subfolders" method, select them, click "View > update files from catalog" wait a while. Repeat for all folders.
or
2- If you don't have many categories , Enable export, click a 1st category in "categories filter" , select all JPGs found, unmark / mark slowly this category in "categories" pane , unselect photos to make the keywords be written. Repeat these actions for all categories of "categories filter" pane ...

Now JPG photos have embedded keywords.
In the new PC, enable "Import" (Settings > metadata) , and click on "Import Folders" button in "Settings > Catalog ".
Select the parent folder for all your photos > This will take a while .

B) Without keywords
- Modify XnView.db file in order to make it work in the new computer ... perhaps Pierre can help you
Last but not the least :
- Use File's categories > Export ... (located at the top of categories pane) into a XML file. Edit this file, and with a text tool, replace old paths by new paths. In the new computer, use Files's categories > Import ...
It's the easiest way, but star ratings and color labels are not saved this way.
Does XnView MP support moving files over a network? Is there another forum post with the answer? I know there's a move folder function within MP, but I am not sure on how to do this between two computers.
I don't know the answers to these questions ...
LordB
Posts: 6
Joined: Sat Aug 17, 2019 3:55 pm

Re: Move files to new drive, how to perserve categories.

Post by LordB »

All of the images are PNG files. Is it possible to add this metadata to them?
User avatar
michel038
Posts: 786
Joined: Tue Sep 27, 2016 8:18 am
Location: France

Re: Move files to new drive, how to perserve categories.

Post by michel038 »

It seems thet XnViewMP can't use iptc embedded metadata for png files, but it's possible to use xmp standard.

If you want to export categories into embedded xmp keywords, select Options>Settings>Metadata>Export categories and "Create xmp" (not iptc)
I think you can also embed star ratings and color labels (if you used them) by checking options below in the same settings window .
And use one of the methods as I described ... but it's a bit long.

You can before use the last method , without keywords, for test if all your png files are already copied in the new computer
Export xmp file of 1st PC, edit paths according to the new location of images , and import the xmp file in the new PC
LordB
Posts: 6
Joined: Sat Aug 17, 2019 3:55 pm

Re: Move files to new drive, how to perserve categories.

Post by LordB »

Could you perhaps post some images of how you are doing this? I tried the method of updating files from catalog, but after taking a long amount of time, I can't see anything changing in the files themselves. How do you verify the process actually worked and the files now have the keyword embedded? This is about creating a keyword from the Category names right? I should be able to open the image in another program and see the keyword bound to the file correct?
User avatar
xnview
Author of XnView
Posts: 36461
Joined: Mon Oct 13, 2003 7:31 am
Location: France

Re: Move files to new drive, how to perserve categories.

Post by xnview »

LordB wrote: Wed Nov 17, 2021 4:30 pm All of the images are PNG files. Is it possible to add this metadata to them?
Do you store categories in XMP metadata?
Pierre.
User avatar
michel038
Posts: 786
Joined: Tue Sep 27, 2016 8:18 am
Location: France

Re: Move files to new drive, how to perserve categories.

Post by michel038 »

Start
export1.png
Then
export2.png
:D

My Windows 7 does not show XMP keywords in png files , but it does in jpg files ...
You do not have the required permissions to view the files attached to this post.
LordB
Posts: 6
Joined: Sat Aug 17, 2019 3:55 pm

Re: Move files to new drive, how to perserve categories.

Post by LordB »

Thank you. I was able to move all the files successfully with a combination of the XMP tagging and windows built in robocopy cmd tool. I really appreciate the help.