You can pass anything you like (custom class instances, functions, nested lists, dictionaries etc) between GHPython components, by setting the input parameter type hint to No Type Hint. This is actually one of the things I really like/prefer about GHPython (as opposed to the other scripting components, if I understand how they work accurately). This can also aid in severely speeding things up by not casting/exposing large chunks of data to the GH canvas.