Improved structure to object back and forth conversion