Skip to content

Fix tf.py LoadImages() dataloader return values#5455

Merged
glenn-jocher merged 1 commit intomasterfrom
fix/tf
Nov 2, 2021
Merged

Fix tf.py LoadImages() dataloader return values#5455
glenn-jocher merged 1 commit intomasterfrom
fix/tf

Conversation

@glenn-jocher
Copy link
Copy Markdown
Member

@glenn-jocher glenn-jocher commented Nov 2, 2021

Fix for #5446 (comment)

Additional LoadImages() dataloader 'string' return value defined in logging PR #4854.

@zldrobit be aware PR #4854 may affect your other TF export tools based on master that use representative_dataset generator.

🛠️ PR Summary

Made with ❤️ by Ultralytics Actions

🌟 Summary

Upgrade of the representative dataset generator function with additional data handling.

📊 Key Changes

  • Altered the tuple structure unpacked during dataset iteration to include a string element.

🎯 Purpose & Impact

  • The change allows the generator to handle an additional string data point per dataset item. This could potentially enable more descriptive dataset outputs or support new features that rely on string-based data representation.
  • Users may see improved dataset handling, particularly where a string identifier or descriptor is essential. However, this requires changes in dataset preparation to include the string component.

@glenn-jocher glenn-jocher linked an issue Nov 2, 2021 that may be closed by this pull request
2 tasks
@glenn-jocher glenn-jocher merged commit 042f02f into master Nov 2, 2021
@glenn-jocher glenn-jocher deleted the fix/tf branch November 2, 2021 22:04
@glenn-jocher glenn-jocher self-assigned this Nov 2, 2021
@zldrobit
Copy link
Copy Markdown
Contributor

zldrobit commented Nov 3, 2021

@glenn-jocher Thanks for reminding me. The only TF tool using representative_dataset is the int8 quantization of TFLite, which does not affect the Saved Model, GraphDef (pb) and tfjs export.

BjarneKuehl pushed a commit to fhkiel-mlaip/yolov5 that referenced this pull request Aug 26, 2022
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

Successfully merging this pull request may close these issues.

export failure for tflite with options (--half and --int8)

2 participants