Hi Jackson, it looks like there’s a bug when converting to a dictionary that doesn’t include the extra attrs I attached on the fly.
When used not as a dict:
fa = FieldAnalysis…
fa.analyze()
d = fa.results_data()
then we can access the flatness and symmetry values like so: d.flatness_horizontal, d.flatness_vertical, d.symmetry_vertical, d.symmetry_horizontal
However, because these attrs are added on the fly they are not true dataclasses attrs and it looks like when it gets converted to a dict then it drops those extra attrs. I’ll have a bugfix up soon.
Cool, thanks for the tip on accessing it through the results_data object. I briefly searched the object attributes, but I guess I only used iPython live introspection, which didn’t show it.
I was trying to “run” the function and see the attributes all in a single line, as shown in the attachment. That way must use some shortcut to show the object’s attributes (I guess it doesn’t actually run the function). When I actually defined the object as a variable, as you did, I could see all its attributes, including flatness and symmetry. Operator error