Given an array of product objects with attributes like size and color, find duplicates or identify non-conforming data formats.
Implement find_product_duplicates(products). A valid product is a dictionary containing non-empty string values for size and color; extra fields are allowed. Return a dictionary with duplicates, a list of index groups for repeated (size, color) pairs, and invalid, the indices of malformed products. Preserve input order within groups and group order by first occurrence.
size and color(size, color)def find_product_duplicates(products):