EXIF Error when reading from JPG Training Faces

If training is failing to start, and you are not receiving an error message telling you what to do, tell us about it here


Forum rules

Read the FAQs and search the forum before posting a new topic.

This forum is for reporting errors with the Training process. If you want to get tips, or better understand the Training process, then you should look in the Training Discussion forum.

Please mark any answers that fixed your problems so others can find the solutions.

Locked
User avatar
ianstephens
Posts: 117
Joined: Sun Feb 14, 2021 7:20 pm
Has thanked: 12 times
Been thanked: 15 times

EXIF Error when reading from JPG Training Faces

Post by ianstephens »

Hi there,

My first post here although we have been using the project for many months and have been following the forums.

Firstly, thank you very much for creating such a package and bringing everything into one place on multiple platforms. This project is fantastic and I will first ask for a link to where I can donate to this project?

Secondly, moving on to my issue.

We have just updated to the latest version/packages using the update option inside Faceswap.

We have been successfully using the project for many months with no issues.

However, once updated we have gone to continue training one of our existing models and it does not run.

We now get the following when trying to run training on one of our existing models;

Code: Select all

ValueError: Only png files are supported for reading exif data.

Our training set has a mix of JPEG/PNG files. We correctly used the extract process inside Faceswap before the update, which extracts faces from JPG images and saves them as JPG and extracts faces from video sources and saves them as PNG.

The issue is with the JPG files inside the existing training faces folder.

We had no issues before but since the latest update, we are now unable to train using our existing data.

Any help, fixes, or suggestions are greatly appreciated.

Thank you for your help in advance.

by torzdf » Mon Feb 15, 2021 4:48 pm

There's always someone who wants to do something outside of the design spec ;)

This should now ignore pre-existing iTXt headers and pull in the correct data.

Go to full post
Last edited by ianstephens on Sun Feb 14, 2021 7:31 pm, edited 1 time in total.
User avatar
torzdf
Posts: 2649
Joined: Fri Jul 12, 2019 12:53 am
Answers: 159
Has thanked: 128 times
Been thanked: 622 times

Re: EXIF Error when reading from JPG Training Faces

Post by torzdf »

I updated (like literally an hour ago) to remove the requirements for alignments files in training.... One of the pre-requisites for this is that training images need to be pngs....

All is not lost, I have programmed it in a way that it will auto-update your facesets.... however, it would appear that the auto-update is not expecting jpgs....

If you can hold fire for 24 hours, I should be able to get this fixed tomorrow.

My word is final

User avatar
ianstephens
Posts: 117
Joined: Sun Feb 14, 2021 7:20 pm
Has thanked: 12 times
Been thanked: 15 times

Re: EXIF Error when reading from JPG Training Faces

Post by ianstephens »

Thank you for your reply!

Well typical for me to catch a bug as soon as it's released :lol:

So no alignments required for training - I presume they are now stored in the EXIF data it's trying to extract? Does that mean all new extraction alignments going forward will be stored within the image file? What about masking data? Also what if the MD5 of the file changes (if we run color fixing etc) after extraction? Apologies for the many questions - I'm sure you have all of this covered.

No problem - I'll let our GPUs cool down this evening and then turn on the AC tomorrow once you've patched it :)

I also noticed you've moved warp disabling into the main GUI now - that's handy.

Do you have a link as to where I can donate to this project?

User avatar
torzdf
Posts: 2649
Joined: Fri Jul 12, 2019 12:53 am
Answers: 159
Has thanked: 128 times
Been thanked: 622 times

Re: EXIF Error when reading from JPG Training Faces

Post by torzdf »

ianstephens wrote: Sun Feb 14, 2021 7:37 pm

So no alignments required for training - I presume they are now stored in the EXIF data it's trying to extract?

Does that mean all new extraction alignments going forward will be stored within the image file? What about masking data?

Yes. The implementation basically follows PNG Specification, so (theoretically) opening these files in other software should respect the header. Color fixing and re-saving will depend on a package by package basis though. I cannot guarantee that Faceswap data will not be stripped by 3rd party tools. Mask data is also stored in the header.

Also what if the MD5 of the file changes (if we run color fixing etc) after extraction?

Hashes are no longer used to track faces. it is now purely down to header data, so as long as the 3rd party software maintains the header information, it will be fine. Note that this is only the case for new extracts or automatically updated facesets.

Worth bearing in mind that the alignments file from the source frames still remains the "Master" document. The information contained in the png header just contains a copy of this data, but it helps remove the disconnect which occurs when alignments files serve two purposes (convert position mapping, and information for training), and removes the requirement to merge alignments files. Once your faceset has been updated, you will be able to safely delete your training alignments and not have to worry about them again.

Do you have a link as to where I can donate to this project?

Of course... choose your weapon ;)
Patreon: https://www.patreon.com/bePatron?u=23238350
Paypal: https://www.paypal.com/cgi-bin/webscr?c ... PP3YE9J62L
Bitcoin: bc1qpm22suz59ylzk0j7qk5e4c7cnkjmve2rmtrnc6
Ethereum: 0xd3e954dC241B87C4E8E1A801ada485DC1d530F01
Monero: 45dLrtQZ2pkHizBpt3P3yyJKkhcFHnhfNYPMSnz3yVEbdWm3Hj6Kr5TgmGAn3Far8LVaQf1th2n3DJVTRkfeB5ZkHxWozSX

My word is final

User avatar
torzdf
Posts: 2649
Joined: Fri Jul 12, 2019 12:53 am
Answers: 159
Has thanked: 128 times
Been thanked: 622 times

Re: EXIF Error when reading from JPG Training Faces

Post by torzdf »

Should be fixed in latest commit, although I have no .jpg data handy to test with..

My word is final

User avatar
ianstephens
Posts: 117
Joined: Sun Feb 14, 2021 7:20 pm
Has thanked: 12 times
Been thanked: 15 times

Re: EXIF Error when reading from JPG Training Faces

Post by ianstephens »

Morning torzdf,

Donation sent over a little while ago via PayPal :)

Including the alignments and masks into the image file is a fantastic idea and as you said makes merging datasets much easier.

Agree, we will have to beware of image editing software that rewrites the entire image and strips the header/metadata.

Moving on to the issue...

I updated just now and attempted to train an existing model with existing faces - now we have a different error. It's not being so specific anymore re. JPG data but we now get this:

Code: Select all

...
File "C:\Users\USER\faceswap\plugins\train\trainer\_base.py", line 1140, in _load_detected_faces
self._validate_image_size(side, filename, meta["width"], meta["height"])
KeyError: 'width'
User avatar
torzdf
Posts: 2649
Joined: Fri Jul 12, 2019 12:53 am
Answers: 159
Has thanked: 128 times
Been thanked: 622 times

Re: EXIF Error when reading from JPG Training Faces

Post by torzdf »

Could you provide the full crash report from your Faceswap folder please?

I suspect that this is also due to an upgrade from jpg to png (and suspect the process will work if you kick it off again, as the files should have been updated at this point), however I would still like to catch and handle this error.

My word is final

User avatar
ianstephens
Posts: 117
Joined: Sun Feb 14, 2021 7:20 pm
Has thanked: 12 times
Been thanked: 15 times

Re: EXIF Error when reading from JPG Training Faces

Post by ianstephens »

Attempted to kick it off again - tried running it a few times with the same result. Would you like me to paste the whole .log here or link to it on pastebin or something?

I don't want to fill the whole thread up with lots of logs - unless you are fine with that :D

User avatar
torzdf
Posts: 2649
Joined: Fri Jul 12, 2019 12:53 am
Answers: 159
Has thanked: 128 times
Been thanked: 622 times

Re: EXIF Error when reading from JPG Training Faces

Post by torzdf »

Pasting the log here is fine. If you wrap it in a [code] [/code] block it will format it correctly.

My word is final

User avatar
ianstephens
Posts: 117
Joined: Sun Feb 14, 2021 7:20 pm
Has thanked: 12 times
Been thanked: 15 times

Re: EXIF Error when reading from JPG Training Faces

Post by ianstephens »

Latest error log:

Code: Select all

02/15/2021 11:03:46 MainProcess     _training_0                    _config         load_module                    DEBUG    Added defaults: model.unbalanced
02/15/2021 11:03:46 MainProcess     _training_0                    _config         load_module                    DEBUG    Adding defaults: (filename: villain_defaults.py, module_path: plugins.train.model, plugin_type: model
02/15/2021 11:03:46 MainProcess     _training_0                    _config         load_module                    DEBUG    Importing defaults module: plugins.train.model.villain_defaults
02/15/2021 11:03:46 MainProcess     _training_0                    config          add_section                    DEBUG    Add section: (title: 'model.villain', info: 'A Higher resolution version of the Original Model by VillainGuy.\nExtremely VRAM heavy. Don't try to run this if you have a small GPU.\n\nNB: Unless specifically stated, values changed here will only take effect when creating a new model.')
02/15/2021 11:03:46 MainProcess     _training_0                    config          add_item                       DEBUG    Add item: (section: 'model.villain', title: 'lowmem', datatype: '<class 'bool'>', default: 'False', info: 'Lower memory mode. Set to 'True' if having issues with VRAM useage.\nNB: Models with a changed lowmem mode are not compatible with each other.', rounding: 'None', min_max: None, choices: [], gui_radio: False, fixed: True, group: settings)
02/15/2021 11:03:46 MainProcess     _training_0                    _config         load_module                    DEBUG    Added defaults: model.villain
02/15/2021 11:03:46 MainProcess     _training_0                    _config         load_module                    DEBUG    Adding defaults: (filename: original_defaults.py, module_path: plugins.train.trainer, plugin_type: trainer
02/15/2021 11:03:46 MainProcess     _training_0                    _config         load_module                    DEBUG    Importing defaults module: plugins.train.trainer.original_defaults
02/15/2021 11:03:46 MainProcess     _training_0                    config          add_section                    DEBUG    Add section: (title: 'trainer.original', info: 'Original Trainer Options.\nWARNING: The defaults for augmentation will be fine for 99.9% of use cases. Only change them if you absolutely know what you are doing!')
02/15/2021 11:03:46 MainProcess     _training_0                    config          add_item                       DEBUG    Add item: (section: 'trainer.original', title: 'preview_images', datatype: '<class 'int'>', default: '14', info: 'Number of sample faces to display for each side in the preview when training.', rounding: '2', min_max: (2, 16), choices: None, gui_radio: False, fixed: True, group: evaluation)
02/15/2021 11:03:46 MainProcess     _training_0                    config          add_item                       DEBUG    Add item: (section: 'trainer.original', title: 'zoom_amount', datatype: '<class 'int'>', default: '5', info: 'Percentage amount to randomly zoom each training image in and out.', rounding: '1', min_max: (0, 25), choices: None, gui_radio: False, fixed: True, group: image augmentation)
02/15/2021 11:03:46 MainProcess     _training_0                    config          add_item                       DEBUG    Add item: (section: 'trainer.original', title: 'rotation_range', datatype: '<class 'int'>', default: '10', info: 'Percentage amount to randomly rotate each training image.', rounding: '1', min_max: (0, 25), choices: None, gui_radio: False, fixed: True, group: image augmentation)
02/15/2021 11:03:46 MainProcess     _training_0                    config          add_item                       DEBUG    Add item: (section: 'trainer.original', title: 'shift_range', datatype: '<class 'int'>', default: '5', info: 'Percentage amount to randomly shift each training image horizontally and vertically.', rounding: '1', min_max: (0, 25), choices: None, gui_radio: False, fixed: True, group: image augmentation)
02/15/2021 11:03:46 MainProcess     _training_0                    config          add_item                       DEBUG    Add item: (section: 'trainer.original', title: 'flip_chance', datatype: '<class 'int'>', default: '50', info: 'Percentage chance to randomly flip each training image horizontally.\nNB: This is ignored if the 'no-flip' option is enabled', rounding: '1', min_max: (0, 75), choices: None, gui_radio: False, fixed: True, group: image augmentation)
02/15/2021 11:03:46 MainProcess     _training_0                    config          add_item                       DEBUG    Add item: (section: 'trainer.original', title: 'color_lightness', datatype: '<class 'int'>', default: '30', info: 'Percentage amount to randomly alter the lightness of each training image.\nNB: This is ignored if the 'no-flip' option is enabled', rounding: '1', min_max: (0, 75), choices: None, gui_radio: False, fixed: True, group: color augmentation)
02/15/2021 11:03:46 MainProcess     _training_0                    config          add_item                       DEBUG    Add item: (section: 'trainer.original', title: 'color_ab', datatype: '<class 'int'>', default: '8', info: 'Percentage amount to randomly alter the 'a' and 'b' colors of the L*a*b* color space of each training image.\nNB: This is ignored if the 'no-flip' option is enabled', rounding: '1', min_max: (0, 50), choices: None, gui_radio: False, fixed: True, group: color augmentation)
02/15/2021 11:03:46 MainProcess     _training_0                    config          add_item                       DEBUG    Add item: (section: 'trainer.original', title: 'color_clahe_chance', datatype: '<class 'int'>', default: '50', info: 'Percentage chance to perform Contrast Limited Adaptive Histogram Equalization on each training image.\nNB: This is ignored if the 'no-augment-color' option is enabled', rounding: '1', min_max: (0, 75), choices: None, gui_radio: False, fixed: False, group: color augmentation)
02/15/2021 11:03:46 MainProcess     _training_0                    config          add_item                       DEBUG    Add item: (section: 'trainer.original', title: 'color_clahe_max_size', datatype: '<class 'int'>', default: '4', info: 'The grid size dictates how much Contrast Limited Adaptive Histogram Equalization is performed on any training image selected for clahe. Contrast will be applied randomly with a gridsize of 0 up to the maximum. This value is a multiplier calculated from the training image size.\nNB: This is ignored if the 'no-augment-color' option is enabled', rounding: '1', min_max: (1, 8), choices: None, gui_radio: False, fixed: True, group: color augmentation)
02/15/2021 11:03:46 MainProcess     _training_0                    _config         load_module                    DEBUG    Added defaults: trainer.original
02/15/2021 11:03:46 MainProcess     _training_0                    config          handle_config                  DEBUG    Handling config
02/15/2021 11:03:46 MainProcess     _training_0                    config          check_exists                   DEBUG    Config file exists: 'C:\Users\USER\faceswap\config\train.ini'
02/15/2021 11:03:46 MainProcess     _training_0                    config          load_config                    VERBOSE  Loading config: 'C:\Users\USER\faceswap\config\train.ini'
02/15/2021 11:03:46 MainProcess     _training_0                    config          validate_config                DEBUG    Validating config
02/15/2021 11:03:46 MainProcess     _training_0                    config          check_config_change            DEBUG    Default config has not changed
02/15/2021 11:03:46 MainProcess     _training_0                    config          check_config_choices           DEBUG    Checking config choices
02/15/2021 11:03:46 MainProcess     _training_0                    config          check_config_choices           DEBUG    Checked config choices
02/15/2021 11:03:46 MainProcess     _training_0                    config          validate_config                DEBUG    Validated config
02/15/2021 11:03:46 MainProcess     _training_0                    config          handle_config                  DEBUG    Handled config
02/15/2021 11:03:46 MainProcess     _training_0                    config          __init__                       DEBUG    Initialized: Config
02/15/2021 11:03:46 MainProcess     _training_0                    config          get                            DEBUG    Getting config item: (section: 'global', option: 'centering')
02/15/2021 11:03:46 MainProcess     _training_0                    config          get                            DEBUG    Returning item: (type: <class 'str'>, value: face)
02/15/2021 11:03:46 MainProcess     _training_0                    config          get                            DEBUG    Getting config item: (section: 'global', option: 'coverage')
02/15/2021 11:03:46 MainProcess     _training_0                    config          get                            DEBUG    Returning item: (type: <class 'float'>, value: 95.0)
02/15/2021 11:03:46 MainProcess     _training_0                    config          get                            DEBUG    Getting config item: (section: 'global', option: 'icnr_init')
02/15/2021 11:03:46 MainProcess     _training_0                    config          get                            DEBUG    Returning item: (type: <class 'bool'>, value: False)
02/15/2021 11:03:46 MainProcess     _training_0                    config          get                            DEBUG    Getting config item: (section: 'global', option: 'conv_aware_init')
02/15/2021 11:03:46 MainProcess     _training_0                    config          get                            DEBUG    Returning item: (type: <class 'bool'>, value: True)
02/15/2021 11:03:46 MainProcess     _training_0                    config          get                            DEBUG    Getting config item: (section: 'global', option: 'optimizer')
02/15/2021 11:03:46 MainProcess     _training_0                    config          get                            DEBUG    Returning item: (type: <class 'str'>, value: adam)
02/15/2021 11:03:46 MainProcess     _training_0                    config          get                            DEBUG    Getting config item: (section: 'global', option: 'learning_rate')
02/15/2021 11:03:46 MainProcess     _training_0                    config          get                            DEBUG    Returning item: (type: <class 'float'>, value: 5e-05)
02/15/2021 11:03:46 MainProcess     _training_0                    config          get                            DEBUG    Getting config item: (section: 'global', option: 'reflect_padding')
02/15/2021 11:03:46 MainProcess     _training_0                    config          get                            DEBUG    Returning item: (type: <class 'bool'>, value: True)
02/15/2021 11:03:46 MainProcess     _training_0                    config          get                            DEBUG    Getting config item: (section: 'global', option: 'allow_growth')
02/15/2021 11:03:46 MainProcess     _training_0                    config          get                            DEBUG    Returning item: (type: <class 'bool'>, value: False)
02/15/2021 11:03:46 MainProcess     _training_0                    config          get                            DEBUG    Getting config item: (section: 'global', option: 'mixed_precision')
02/15/2021 11:03:46 MainProcess     _training_0                    config          get                            DEBUG    Returning item: (type: <class 'bool'>, value: True)
02/15/2021 11:03:46 MainProcess     _training_0                    config          get                            DEBUG    Getting config item: (section: 'global', option: 'convert_batchsize')
02/15/2021 11:03:46 MainProcess     _training_0                    config          get                            DEBUG    Returning item: (type: <class 'int'>, value: 16)
02/15/2021 11:03:46 MainProcess     _training_0                    config          get                            DEBUG    Getting config item: (section: 'global.loss', option: 'loss_function')
02/15/2021 11:03:46 MainProcess     _training_0                    config          get                            DEBUG    Returning item: (type: <class 'str'>, value: ssim)
02/15/2021 11:03:46 MainProcess     _training_0                    config          get                            DEBUG    Getting config item: (section: 'global.loss', option: 'mask_loss_function')
02/15/2021 11:03:46 MainProcess     _training_0                    config          get                            DEBUG    Returning item: (type: <class 'str'>, value: mse)
02/15/2021 11:03:46 MainProcess     _training_0                    config          get                            DEBUG    Getting config item: (section: 'global.loss', option: 'l2_reg_term')
02/15/2021 11:03:46 MainProcess     _training_0                    config          get                            DEBUG    Returning item: (type: <class 'int'>, value: 100)
02/15/2021 11:03:46 MainProcess     _training_0                    config          get                            DEBUG    Getting config item: (section: 'global.loss', option: 'eye_multiplier')
02/15/2021 11:03:46 MainProcess     _training_0                    config          get                            DEBUG    Returning item: (type: <class 'int'>, value: 3)
02/15/2021 11:03:46 MainProcess     _training_0                    config          get                            DEBUG    Getting config item: (section: 'global.loss', option: 'mouth_multiplier')
02/15/2021 11:03:46 MainProcess     _training_0                    config          get                            DEBUG    Returning item: (type: <class 'int'>, value: 2)
02/15/2021 11:03:46 MainProcess     _training_0                    config          get                            DEBUG    Getting config item: (section: 'global.loss', option: 'penalized_mask_loss')
02/15/2021 11:03:46 MainProcess     _training_0                    config          get                            DEBUG    Returning item: (type: <class 'bool'>, value: True)
02/15/2021 11:03:46 MainProcess     _training_0                    config          get                            DEBUG    Getting config item: (section: 'global.loss', option: 'mask_type')
02/15/2021 11:03:46 MainProcess     _training_0                    config          get                            DEBUG    Returning item: (type: <class 'str'>, value: extended)
02/15/2021 11:03:46 MainProcess     _training_0                    config          get                            DEBUG    Getting config item: (section: 'global.loss', option: 'mask_blur_kernel')
02/15/2021 11:03:46 MainProcess     _training_0                    config          get                            DEBUG    Returning item: (type: <class 'int'>, value: 3)
02/15/2021 11:03:46 MainProcess     _training_0                    config          get                            DEBUG    Getting config item: (section: 'global.loss', option: 'mask_threshold')
02/15/2021 11:03:46 MainProcess     _training_0                    config          get                            DEBUG    Returning item: (type: <class 'int'>, value: 4)
02/15/2021 11:03:46 MainProcess     _training_0                    config          get                            DEBUG    Getting config item: (section: 'global.loss', option: 'learn_mask')
02/15/2021 11:03:46 MainProcess     _training_0                    config          get                            DEBUG    Returning item: (type: <class 'bool'>, value: False)
02/15/2021 11:03:46 MainProcess     _training_0                    config          get                            DEBUG    Getting config item: (section: 'trainer.original', option: 'preview_images')
02/15/2021 11:03:46 MainProcess     _training_0                    config          get                            DEBUG    Returning item: (type: <class 'int'>, value: 14)
02/15/2021 11:03:46 MainProcess     _training_0                    config          get                            DEBUG    Getting config item: (section: 'trainer.original', option: 'zoom_amount')
02/15/2021 11:03:46 MainProcess     _training_0                    config          get                            DEBUG    Returning item: (type: <class 'int'>, value: 5)
02/15/2021 11:03:46 MainProcess     _training_0                    config          get                            DEBUG    Getting config item: (section: 'trainer.original', option: 'rotation_range')
02/15/2021 11:03:46 MainProcess     _training_0                    config          get                            DEBUG    Returning item: (type: <class 'int'>, value: 10)
02/15/2021 11:03:46 MainProcess     _training_0                    config          get                            DEBUG    Getting config item: (section: 'trainer.original', option: 'shift_range')
02/15/2021 11:03:46 MainProcess     _training_0                    config          get                            DEBUG    Returning item: (type: <class 'int'>, value: 5)
02/15/2021 11:03:46 MainProcess     _training_0                    config          get                            DEBUG    Getting config item: (section: 'trainer.original', option: 'flip_chance')
02/15/2021 11:03:46 MainProcess     _training_0                    config          get                            DEBUG    Returning item: (type: <class 'int'>, value: 50)
02/15/2021 11:03:46 MainProcess     _training_0                    config          get                            DEBUG    Getting config item: (section: 'trainer.original', option: 'color_lightness')
02/15/2021 11:03:46 MainProcess     _training_0                    config          get                            DEBUG    Returning item: (type: <class 'int'>, value: 30)
02/15/2021 11:03:46 MainProcess     _training_0                    config          get                            DEBUG    Getting config item: (section: 'trainer.original', option: 'color_ab')
02/15/2021 11:03:46 MainProcess     _training_0                    config          get                            DEBUG    Returning item: (type: <class 'int'>, value: 8)
02/15/2021 11:03:46 MainProcess     _training_0                    config          get                            DEBUG    Getting config item: (section: 'trainer.original', option: 'color_clahe_chance')
02/15/2021 11:03:46 MainProcess     _training_0                    config          get                            DEBUG    Returning item: (type: <class 'int'>, value: 50)
02/15/2021 11:03:46 MainProcess     _training_0                    config          get                            DEBUG    Getting config item: (section: 'trainer.original', option: 'color_clahe_max_size')
02/15/2021 11:03:46 MainProcess     _training_0                    config          get                            DEBUG    Returning item: (type: <class 'int'>, value: 4)
02/15/2021 11:03:46 MainProcess     _training_0                    _base           add_session_batchsize          DEBUG    Adding session batch size: 13
02/15/2021 11:03:46 MainProcess     _training_0                    _base           __init__                       DEBUG    Initializing _TrainingAlignments: (model: <plugins.train.model.dfl_sae.Model object at 0x000002124BDE5DC0>, image counts: {'a': 3497, 'b': 1513})
02/15/2021 11:03:46 MainProcess     _training_0                    _base           _load_detected_faces           DEBUG    side: a, file count: 3497
02/15/2021 11:03:46 MainProcess     _training_0                    image           read_image_meta_batch          DEBUG    Submitting 3497 items to executor
02/15/2021 11:03:46 MainProcess     _training_0                    image           read_image_meta_batch          DEBUG    Succesfully submitted 3497 items to executor
02/15/2021 11:03:46 MainProcess     _training_0                    multithreading  run                            DEBUG    Error in thread (_training_0): 'width'
02/15/2021 11:03:47 MainProcess     MainThread                     train           _monitor                       DEBUG    Thread error detected
02/15/2021 11:03:47 MainProcess     MainThread                     train           _monitor                       DEBUG    Closed Monitor
02/15/2021 11:03:47 MainProcess     MainThread                     train           _end_thread                    DEBUG    Ending Training thread
02/15/2021 11:03:47 MainProcess     MainThread                     train           _end_thread                    CRITICAL Error caught! Exiting...
02/15/2021 11:03:47 MainProcess     MainThread                     multithreading  join                           DEBUG    Joining Threads: '_training'
02/15/2021 11:03:47 MainProcess     MainThread                     multithreading  join                           DEBUG    Joining Thread: '_training_0'
02/15/2021 11:03:47 MainProcess     MainThread                     multithreading  join                           ERROR    Caught exception in thread: '_training_0'
Traceback (most recent call last):
  File "C:\Users\USER\faceswap\lib\cli\launcher.py", line 182, in execute_script
    process.process()
  File "C:\Users\USER\faceswap\scripts\train.py", line 170, in process
    self._end_thread(thread, err)
  File "C:\Users\USER\faceswap\scripts\train.py", line 210, in _end_thread
    thread.join()
  File "C:\Users\USER\faceswap\lib\multithreading.py", line 121, in join
    raise thread.err[1].with_traceback(thread.err[2])
  File "C:\Users\USER\faceswap\lib\multithreading.py", line 37, in run
    self._target(*self._args, **self._kwargs)
  File "C:\Users\USER\faceswap\scripts\train.py", line 232, in _training
    raise err
  File "C:\Users\USER\faceswap\scripts\train.py", line 221, in _training
    trainer = self._load_trainer(model)
  File "C:\Users\USER\faceswap\scripts\train.py", line 267, in _load_trainer
    trainer = trainer(model,
  File "C:\Users\USER\faceswap\plugins\train\trainer\original.py", line 10, in __init__
    super().__init__(*args, **kwargs)
  File "C:\Users\USER\faceswap\plugins\train\trainer\_base.py", line 83, in __init__
    alignment_data = self._get_alignments_data()
  File "C:\Users\USER\faceswap\plugins\train\trainer\_base.py", line 143, in _get_alignments_data
    alignments = _TrainingAlignments(self._model, self._images)
  File "C:\Users\USER\faceswap\plugins\train\trainer\_base.py", line 1090, in __init__
    self._detected_faces = self._load_detected_faces(image_list)
  File "C:\Users\USER\faceswap\plugins\train\trainer\_base.py", line 1140, in _load_detected_faces
    self._validate_image_size(side, filename, meta["width"], meta["height"])
KeyError: 'width'

============ System Information ============
encoding:            cp1252
git_branch:          master
git_commits:         fcf6d82 Bugfixes:   - lib.image Don't raise error if legacy non-png is found when reading header data   - plugins.train.trainer._base - Correctly pass legacy alignments through to DetectedFace. b1cfbe4 Update extracted faces to use PNG EXIF data (#1123). a84462f Training - Move disable warp option out of config. ec3fb8b gui - bugfix: Clear recent files on data corruption. 57b29b0 preview tool: bugfix ttk.PanedWindow
gpu_cuda:            No global version found. Check Conda packages for Conda Cuda
gpu_cudnn:           No global version found. Check Conda packages for Conda cuDNN
gpu_devices:         GPU_0: GeForce RTX 2080 Ti
gpu_devices_active:  GPU_0
gpu_driver:          457.30
gpu_vram:            GPU_0: 11264MB
os_machine:          AMD64
os_platform:         Windows-10-10.0.19041-SP0
os_release:          10
py_command:          C:\Users\USER\faceswap\faceswap.py train -A F:/FSWAP/K6N/Source/Training Set -ala F:/FSWAP/K6N/Source/Training Set/alignments.fsa -B F:/FSWAP/New K/Experimental Training Set -alb F:/FSWAP/New K/Experimental Training Set/alignments.fsa -m F:/FSWAP/K6N/Model DFL SAE DF -t dfl-sae -bs 13 -it 1000000 -s 500 -ss 25000 -ps 75 -nw -L INFO -gui
py_conda_version:    conda 4.9.2
py_implementation:   CPython
py_version:          3.8.5
py_virtual_env:      True
sys_cores:           8
sys_processor:       Intel64 Family 6 Model 62 Stepping 4, GenuineIntel
sys_ram:             Total: 32712MB, Available: 27525MB, Used: 5186MB, Free: 27525MB

=============== Pip Packages ===============


============== Conda Packages ==============
# packages in environment at C:\Users\USER\MiniConda3\envs\394400:
#
# Name                    Version                   Build  Channel
_tflow_select             2.3.0                       gpu  
absl-py 0.11.0 pyhd3eb1b0_1
aiohttp 3.7.3 py38h2bbff1b_1
astunparse 1.6.3 py_0
async-timeout 3.0.1 py38_0
attrs 20.3.0 pyhd3eb1b0_0
blas 1.0 mkl
blinker 1.4 py38_0
brotlipy 0.7.0 py38h2bbff1b_1003
ca-certificates 2020.12.8 haa95532_0
cachetools 4.2.0 pyhd3eb1b0_0
certifi 2020.12.5 py38haa95532_0
cffi 1.14.4 py38hcd4344a_0
chardet 3.0.4 py38haa95532_1003
click 7.1.2 py_0
cryptography 2.9.2 py38h7a1dbc1_0
cudatoolkit 10.1.243 h74a9793_0
cudnn 7.6.5 cuda10.1_0
cycler 0.10.0 py38_0
fastcluster 1.1.26 py38h251f6bf_2 conda-forge ffmpeg 4.3.1 ha925a31_0 conda-forge ffmpy 0.2.3 pypi_0 pypi freetype 2.10.4 hd328e21_0
gast 0.4.0 py_0
git 2.23.0 h6bb4b03_0
google-auth 1.24.0 pyhd3eb1b0_0
google-auth-oauthlib 0.4.2 pyhd3eb1b0_2
google-pasta 0.2.0 py_0
grpcio 1.31.0 py38he7da953_0
h5py 2.10.0 py38h5e291fa_0
hdf5 1.10.4 h7ebc959_0
icc_rt 2019.0.0 h0cc432a_1
icu 58.2 ha925a31_3
idna 2.10 py_0
imageio 2.9.0 py_0
imageio-ffmpeg 0.4.2 py_0 conda-forge importlib-metadata 2.0.0 py_1
intel-openmp 2020.2 254
joblib 1.0.0 pyhd3eb1b0_0
jpeg 9b hb83a4c4_2
keras-applications 1.0.8 py_1
keras-preprocessing 1.1.0 py_1
kiwisolver 1.3.0 py38hd77b12b_0
libpng 1.6.37 h2a8f88b_0
libprotobuf 3.13.0.1 h200bbdf_0
libtiff 4.1.0 h56a325e_1
lz4-c 1.9.2 hf4a77e7_3
markdown 3.3.3 py38haa95532_0
matplotlib 3.2.2 0
matplotlib-base 3.2.2 py38h64f37c6_0
mkl 2020.2 256
mkl-service 2.3.0 py38h196d8e1_0
mkl_fft 1.2.0 py38h45dec08_0
mkl_random 1.1.1 py38h47e9c7a_0
multidict 4.7.6 py38he774522_1
numpy 1.19.2 py38hadc3359_0
numpy-base 1.19.2 py38ha3acd2a_0
nvidia-ml-py3 7.352.1 pypi_0 pypi oauthlib 3.1.0 py_0
olefile 0.46 py_0
opencv-python 4.4.0.46 pypi_0 pypi openssl 1.1.1i h2bbff1b_0
opt_einsum 3.1.0 py_0
pathlib 1.0.1 py_1
pillow 8.0.1 py38h4fa10fc_0
pip 20.3.3 py38haa95532_0
protobuf 3.13.0.1 py38ha925a31_1
psutil 5.7.2 py38he774522_0
pyasn1 0.4.8 py_0
pyasn1-modules 0.2.8 py_0
pycparser 2.20 py_2
pyjwt 2.0.0 py38haa95532_0
pyopenssl 20.0.1 pyhd3eb1b0_1
pyparsing 2.4.7 py_0
pyqt 5.9.2 py38ha925a31_4
pyreadline 2.1 py38_1
pysocks 1.7.1 py38haa95532_0
python 3.8.5 h5fd99cc_1
python-dateutil 2.8.1 py_0
python_abi 3.8 1_cp38 conda-forge pywin32 227 py38he774522_1
qt 5.9.7 vc14h73c81de_0
requests 2.25.1 pyhd3eb1b0_0
requests-oauthlib 1.3.0 py_0
rsa 4.6 py_0
scikit-learn 0.23.2 py38h47e9c7a_0
scipy 1.5.2 py38h14eb087_0
setuptools 51.0.0 py38haa95532_2
sip 4.19.13 py38ha925a31_0
six 1.15.0 py38haa95532_0
sqlite 3.33.0 h2a8f88b_0
tensorboard 2.3.0 pyh4dce500_0
tensorboard-plugin-wit 1.6.0 py_0
tensorflow 2.3.0 mkl_py38h1fcfbd6_0
tensorflow-base 2.3.0 gpu_py38h7339f5a_0
tensorflow-estimator 2.3.0 pyheb71bc4_0
tensorflow-gpu 2.3.0 he13fc11_0
termcolor 1.1.0 py38_1
threadpoolctl 2.1.0 pyh5ca1d4c_0
tk 8.6.10 he774522_0
tornado 6.1 py38h2bbff1b_0
tqdm 4.54.1 pyhd3eb1b0_0
typing-extensions 3.7.4.3 0
typing_extensions 3.7.4.3 py_0
urllib3 1.26.2 pyhd3eb1b0_0
vc 14.2 h21ff451_1
vs2015_runtime 14.27.29016 h5e58377_2
werkzeug 1.0.1 py_0
wheel 0.36.2 pyhd3eb1b0_0
win_inet_pton 1.1.0 py38haa95532_0
wincertstore 0.2 py38_0
wrapt 1.12.1 py38he774522_1
xz 5.2.5 h62dcd97_0
yarl 1.5.1 py38he774522_0
zipp 3.4.0 pyhd3eb1b0_0
zlib 1.2.11 h62dcd97_4
zstd 1.4.5 h04227a9_0 ================= Configs ================== --------- .faceswap --------- backend: nvidia --------- convert.ini --------- [color.color_transfer] clip: True preserve_paper: True [color.manual_balance] colorspace: HSV balance_1: 0.0 balance_2: 0.0 balance_3: 0.0 contrast: 0.0 brightness: 0.0 [color.match_hist] threshold: 99.0 [mask.box_blend] type: gaussian distance: 11.0 radius: 5.0 passes: 1 [mask.mask_blend] type: gaussian kernel_size: 3 passes: 4 threshold: 4 erosion: 0.0 [scaling.sharpen] method: none amount: 150 radius: 0.3 threshold: 5.0 [writer.ffmpeg] container: mp4 codec: libx264 crf: 23 preset: medium tune: None profile: auto level: auto skip_mux: False [writer.gif] fps: 25 loop: 0 palettesize: 256 subrectangles: False [writer.opencv] format: jpg draw_transparent: False jpg_quality: 75 png_compress_level: 3 [writer.pillow] format: jpg draw_transparent: False optimize: False gif_interlace: True jpg_quality: 75 png_compress_level: 3 tif_compression: tiff_deflate --------- extract.ini --------- [global] allow_growth: False [align.fan] batch-size: 12 [detect.cv2_dnn] confidence: 50 [detect.mtcnn] minsize: 20 threshold_1: 0.6 threshold_2: 0.7 threshold_3: 0.7 scalefactor: 0.709 batch-size: 8 [detect.s3fd] confidence: 70 batch-size: 4 [mask.unet_dfl] batch-size: 8 [mask.vgg_clear] batch-size: 6 [mask.vgg_obstructed] batch-size: 2 --------- gui.ini --------- [global] fullscreen: False tab: extract options_panel_width: 30 console_panel_height: 20 icon_size: 14 font: default font_size: 9 autosave_last_session: prompt timeout: 120 auto_load_model_stats: True --------- train.ini --------- [global] centering: face coverage: 95.0 icnr_init: False conv_aware_init: True optimizer: adam learning_rate: 5e-05 reflect_padding: True allow_growth: False mixed_precision: True convert_batchsize: 16 [global.loss] loss_function: ssim mask_loss_function: mse l2_reg_term: 100 eye_multiplier: 3 mouth_multiplier: 2 penalized_mask_loss: True mask_type: extended mask_blur_kernel: 3 mask_threshold: 4 learn_mask: False [model.dfaker] output_size: 128 [model.dfl_h128] lowmem: False [model.dfl_sae] input_size: 192 clipnorm: False architecture: df autoencoder_dims: 0 encoder_dims: 42 decoder_dims: 21 multiscale_decoder: True [model.dlight] features: best details: good output_size: 256 [model.original] lowmem: False [model.realface] input_size: 128 output_size: 256 dense_nodes: 1536 complexity_encoder: 128 complexity_decoder: 512 [model.unbalanced] input_size: 128 lowmem: False clipnorm: True nodes: 1024 complexity_encoder: 128 complexity_decoder_a: 384 complexity_decoder_b: 512 [model.villain] lowmem: False [trainer.original] preview_images: 14 zoom_amount: 5 rotation_range: 10 shift_range: 5 flip_chance: 50 color_lightness: 30 color_ab: 8 color_clahe_chance: 50 color_clahe_max_size: 4
User avatar
torzdf
Posts: 2649
Joined: Fri Jul 12, 2019 12:53 am
Answers: 159
Has thanked: 128 times
Been thanked: 622 times

Re: EXIF Error when reading from JPG Training Faces

Post by torzdf »

Ok. Just pushed an update. Hopefully we've finally got this nailed down!

And many thanks for the donation. Anything and everything is appreciated :)

My word is final

User avatar
ianstephens
Posts: 117
Joined: Sun Feb 14, 2021 7:20 pm
Has thanked: 12 times
Been thanked: 15 times

Re: EXIF Error when reading from JPG Training Faces

Post by ianstephens »

We're getting there... :D

A-side loaded fine this time... however this is what we get when loading the first image from B-side.

Code: Select all

02/15/2021 13:13:04 ERROR    Got Exception on main handler:
Traceback (most recent call last):
File "C:\Users\USER\faceswap\lib\cli\launcher.py", line 182, in execute_script
process.process()
File "C:\Users\USER\faceswap\scripts\train.py", line 170, in process
self._end_thread(thread, err)
File "C:\Users\USER\faceswap\scripts\train.py", line 210, in _end_thread
thread.join()
File "C:\Users\USER\faceswap\lib\multithreading.py", line 121, in join
raise thread.err[1].with_traceback(thread.err[2])
File "C:\Users\USER\faceswap\lib\multithreading.py", line 37, in run
self._target(*self._args, **self._kwargs)
File "C:\Users\USER\faceswap\scripts\train.py", line 232, in _training
raise err
File "C:\Users\USER\faceswap\scripts\train.py", line 221, in _training
trainer = self._load_trainer(model)
File "C:\Users\USER\faceswap\scripts\train.py", line 267, in _load_trainer
trainer = trainer(model,
File "C:\Users\USER\faceswap\plugins\train\trainer\original.py", line 10, in __init__
super().__init__(*args, **kwargs)
File "C:\Users\USER\faceswap\plugins\train\trainer\_base.py", line 83, in __init__
alignment_data = self._get_alignments_data()
File "C:\Users\USER\faceswap\plugins\train\trainer\_base.py", line 143, in _get_alignments_data
alignments = _TrainingAlignments(self._model, self._images)
File "C:\Users\USER\faceswap\plugins\train\trainer\_base.py", line 1090, in __init__
self._detected_faces = self._load_detected_faces(image_list)
File "C:\Users\USER\faceswap\plugins\train\trainer\_base.py", line 1135, in _load_detected_faces
for filename, meta in tqdm(read_image_meta_batch(filelist),
File "C:\Users\USER\MiniConda3\envs\394400\lib\site-packages\tqdm\std.py", line 1167, in __iter__
for obj in iterable:
File "C:\Users\USER\faceswap\lib\image.py", line 438, in read_image_meta_batch
retval = (read_meta[future], future.result())
File "C:\Users\USER\MiniConda3\envs\394400\lib\concurrent\futures\_base.py", line 432, in result
return self.__get_result()
File "C:\Users\USER\MiniConda3\envs\394400\lib\concurrent\futures\_base.py", line 388, in __get_result
raise self._exception
File "C:\Users\USER\MiniConda3\envs\394400\lib\concurrent\futures\thread.py", line 57, in run
result = self.fn(*self.args, **self.kwargs)
File "C:\Users\USER\faceswap\lib\image.py", line 395, in read_image_meta
retval["itxt"] = eval(infile.read(length).split(b"\0\0\0\0\0", 1)[-1])
File "<string>", line 1
<x:xmpmeta xmlns:x="adobe:ns:meta/" x:xmptk="XMP Core 6.0.0">
^
SyntaxError: invalid syntax

With focus on:

Code: Select all

<x:xmpmeta xmlns:x="adobe:ns:meta/" x:xmptk="XMP Core 6.0.0">
^
SyntaxError: invalid syntax

I also ran it a couple of times to see if it would resolve but the error continued.

User avatar
torzdf
Posts: 2649
Joined: Fri Jul 12, 2019 12:53 am
Answers: 159
Has thanked: 128 times
Been thanked: 622 times

Re: EXIF Error when reading from JPG Training Faces

Post by torzdf »

Ok, it looks like the pngs on that side contain metadata that we are not expecting (Faceswap basically expects the metadata to solely have come from Faceswap)

Are you able to provide a selection of png files from that folder (preferably zipped, so they don't get altered) so that I can analyse them and handle? You can direct message me a link if you would prefer.

Thanks

My word is final

User avatar
ianstephens
Posts: 117
Joined: Sun Feb 14, 2021 7:20 pm
Has thanked: 12 times
Been thanked: 15 times

Re: EXIF Error when reading from JPG Training Faces

Post by ianstephens »

torzdf wrote: Mon Feb 15, 2021 12:28 pm

And many thanks for the donation. Anything and everything is appreciated :)

No problem at all. And it won't be a one-off. We will continue supporting the project as we continue using it :)

Also, what is the current status of using RTX 3090? I know TF has issues with compatibility with the new cards.

User avatar
ianstephens
Posts: 117
Joined: Sun Feb 14, 2021 7:20 pm
Has thanked: 12 times
Been thanked: 15 times

Re: EXIF Error when reading from JPG Training Faces

Post by ianstephens »

torzdf wrote: Mon Feb 15, 2021 1:20 pm

Ok, it looks like the pngs on that side contain metadata that we are not expecting (Faceswap basically expects the metadata to solely have come from Faceswap)

Are you able to provide a selection of png files from that folder (preferably zipped, so they don't get altered) so that I can analyse them and handle? You can direct message me a link if you would prefer.

Thanks

With respect, I am unable to share these PNGs for the project. But I can run a dump of the metadata on a sample image and provide that here in the forum for debugging.

All of the PNGs were extracted directly using Faceswap although we did run color correction using external software after extraction - this is possibly where the additional EXIF data is coming from.

What if I was to strip all EXIF/metadata and then run training again? Would it re-add the mask/alignment headers that way using the fallback you scripted?

User avatar
torzdf
Posts: 2649
Joined: Fri Jul 12, 2019 12:53 am
Answers: 159
Has thanked: 128 times
Been thanked: 622 times

Re: EXIF Error when reading from JPG Training Faces

Post by torzdf »

ianstephens wrote: Mon Feb 15, 2021 1:23 pm

Also, what is the current status of using RTX 3090? I know TF has issues with compatibility with the new cards.

Ultimately you can use RTX 3xxx cards (viewtopic.php?f=4&t=1226), but we cannot support it until Conda update their packages for TF2.4 Cuda 11. (https://anaconda.org/anaconda/tensorflow-gpu)

ianstephens wrote: Mon Feb 15, 2021 1:30 pm

With respect, I am unable to share these PNGs for the project. But I can run a dump of the metadata on a sample image and provide that here in the forum for debugging.

All of the PNGs were extracted directly using Faceswap although we did run color correction using external software after extraction - this is possibly where the additional EXIF data is coming from.

What if I was to strip all EXIF/metadata and then run training again? Would it re-add the mask/alignment headers that way using the fallback you scripted?

Possibly, if you can blank out the image data (probably by re-opening it in the software you used, erasing the image, and saving again) this might work. Ultimately I need to parse the raw bytes from the actual image. It looks like an Adobe product was used, so telling me which product/version may also help.

My word is final

User avatar
ianstephens
Posts: 117
Joined: Sun Feb 14, 2021 7:20 pm
Has thanked: 12 times
Been thanked: 15 times

Re: EXIF Error when reading from JPG Training Faces

Post by ianstephens »

torzdf wrote: Mon Feb 15, 2021 1:45 pm

Possibly, if you can blank out the image data (probably by re-opening it in the software you used, erasing the image, and saving again) this might work. Ultimately I need to parse the raw bytes from the actual image. It looks like an Adobe product was used, so telling me which product/version may also help.

Good idea. I will prepare a couple of samples and get them zipped up. I will PM you the link.

Also, I noticed that we have both JPG and PNG in our B-side training set (some were extracted from video files and some were extracted from JPG files).

I'll provide a sample of both.

No, we didn't color correct in an Adobe app but I am aware that Adobe have their own metadata schema/set that a lot of editing software writes to (as well as standard EXIF/XMP/IPTC, etc) to ensure compatibility and full coverage.

However, I will be using Adobe Photoshop to blank out the images :)

User avatar
ianstephens
Posts: 117
Joined: Sun Feb 14, 2021 7:20 pm
Has thanked: 12 times
Been thanked: 15 times

Re: EXIF Error when reading from JPG Training Faces

Post by ianstephens »

I have PM'd you a link to four sample files - 2 JPG and 2 PNG with metadata intact.

Adobe did add some additional metadata when removing the image data however it's essentially the same.

For reference, the RAW output of the image metadata before removing the image data was as follows...

For JPG example:

Code: Select all

<x:xmpmeta xmlns:x="adobe:ns:meta/" x:xmptk="Adobe XMP Core 6.0-c002 79.164488, 2020/07/10-22:06:53        ">
   <rdf:RDF xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#">
      <rdf:Description rdf:about=""
            xmlns:xmp="http://ns.adobe.com/xap/1.0/"
            xmlns:photoshop="http://ns.adobe.com/photoshop/1.0/"
            xmlns:xmpMM="http://ns.adobe.com/xap/1.0/mm/"
            xmlns:dc="http://purl.org/dc/elements/1.1/"
            xmlns:tiff="http://ns.adobe.com/tiff/1.0/"
            xmlns:exif="http://ns.adobe.com/exif/1.0/">
         <xmp:MetadataDate>2021-02-10T12:12:57Z</xmp:MetadataDate>
         <xmp:CreatorTool>Automator 2.10</xmp:CreatorTool>
         <xmp:CreateDate>2021-02-15T14:28:48Z</xmp:CreateDate>
         <xmp:ModifyDate>2021-02-10T12:12:57Z</xmp:ModifyDate>
         <photoshop:LegacyIPTCDigest>D41D8CD98F00B204E9800998ECF8427E</photoshop:LegacyIPTCDigest>
         <photoshop:ColorMode>3</photoshop:ColorMode>
         <photoshop:ICCProfile/>
         <xmpMM:DocumentID>49AF1F739604CC4F3D5BEF1CE669E7F6</xmpMM:DocumentID>
         <xmpMM:InstanceID>49AF1F739604CC4F3D5BEF1CE669E7F6</xmpMM:InstanceID>
         <dc:format>image/jpeg</dc:format>
         <tiff:ImageWidth>256</tiff:ImageWidth>
         <tiff:ImageLength>256</tiff:ImageLength>
         <tiff:BitsPerSample>
            <rdf:Seq>
               <rdf:li>8</rdf:li>
               <rdf:li>8</rdf:li>
               <rdf:li>8</rdf:li>
            </rdf:Seq>
         </tiff:BitsPerSample>
         <tiff:PhotometricInterpretation>2</tiff:PhotometricInterpretation>
         <tiff:Orientation>1</tiff:Orientation>
         <tiff:SamplesPerPixel>3</tiff:SamplesPerPixel>
         <tiff:XResolution>72/1</tiff:XResolution>
         <tiff:YResolution>72/1</tiff:YResolution>
         <tiff:ResolutionUnit>2</tiff:ResolutionUnit>
         <exif:ExifVersion>0231</exif:ExifVersion>
         <exif:ColorSpace>65535</exif:ColorSpace>
         <exif:PixelXDimension>256</exif:PixelXDimension>
         <exif:PixelYDimension>256</exif:PixelYDimension>
      </rdf:Description>
   </rdf:RDF>
</x:xmpmeta>

For PNG example:

Code: Select all

<x:xmpmeta xmlns:x="adobe:ns:meta/" x:xmptk="Adobe XMP Core 6.0-c002 79.164488, 2020/07/10-22:06:53        ">
   <rdf:RDF xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#">
      <rdf:Description rdf:about=""
            xmlns:xmp="http://ns.adobe.com/xap/1.0/"
            xmlns:tiff="http://ns.adobe.com/tiff/1.0/"
            xmlns:exif="http://ns.adobe.com/exif/1.0/"
            xmlns:dc="http://purl.org/dc/elements/1.1/"
            xmlns:photoshop="http://ns.adobe.com/photoshop/1.0/">
         <xmp:CreatorTool>Automator 2.10</xmp:CreatorTool>
         <xmp:MetadataDate>2021-02-05T20:34:17Z</xmp:MetadataDate>
         <xmp:CreateDate>2021-02-15T14:30:09Z</xmp:CreateDate>
         <xmp:ModifyDate>2021-02-05T20:34:17Z</xmp:ModifyDate>
         <tiff:Orientation>1</tiff:Orientation>
         <tiff:XResolution>720000/10000</tiff:XResolution>
         <tiff:YResolution>720000/10000</tiff:YResolution>
         <tiff:ResolutionUnit>2</tiff:ResolutionUnit>
         <exif:PixelXDimension>256</exif:PixelXDimension>
         <exif:PixelYDimension>256</exif:PixelYDimension>
         <dc:format>image/png</dc:format>
         <photoshop:ColorMode>3</photoshop:ColorMode>
         <photoshop:ICCProfile>sRGB IEC61966-2.1</photoshop:ICCProfile>
      </rdf:Description>
   </rdf:RDF>
</x:xmpmeta>

I do believe if I was to strip all of the metadata and run training again it would work - but I want to work with you to get this fixed so that it will also resolve for other users with the same issue :)

User avatar
torzdf
Posts: 2649
Joined: Fri Jul 12, 2019 12:53 am
Answers: 159
Has thanked: 128 times
Been thanked: 622 times

Re: EXIF Error when reading from JPG Training Faces

Post by torzdf »

There's always someone who wants to do something outside of the design spec ;)

This should now ignore pre-existing iTXt headers and pull in the correct data.

My word is final

User avatar
ianstephens
Posts: 117
Joined: Sun Feb 14, 2021 7:20 pm
Has thanked: 12 times
Been thanked: 15 times

Re: EXIF Error when reading from JPG Training Faces

Post by ianstephens »

Well, we have a winner :D

Loaded both sides and once loaded it then went on to convert the legacy images with:

Code: Select all

Updating legacy training images...

Completed that and started the training session.

For good measure, I stopped the session and started again - this time jumping straight into reading the images and beginning training.

Thank you for getting that resolved so quickly.

There's always someone who wants to do something outside of the design spec

Yes indeed, you can never plan for every eventuality when releasing code into the wild. No matter what testing you do - you always miss a scenario you haven't produced yourself. That thrown in with "user error" is a combo for a headache :lol:

Thanks again.

Locked