pyiron_base
pyiron_base copied to clipboard
How to use DataContainer in inspect mode?
When a job is loaded using pr.inspect() then the corresponding DataContainer objects are not loaded. In particular, in the case of pyiron tables which by default use the inspect mode, this becomes an issue.
See #364 and in particular https://github.com/pyiron/pyiron_base/issues/364#issuecomment-1403760357
A quick workaround is to use something like this in a table function
dc = job['location/of/datacontainer'].to_object()
dc['my/fancy/values']
The containers are lazy loaded by default, so the overhead should be small.
By now it's also possible to do
dc = job.content['location/of/datacontainer']
dc['my/fancy/values']