!7 lib 1400166 // jython 2.7 import org.python.core.*; import org.python.modules.cPickle; p-exp { File f = userDir("dev/Relational_Network_Tensorflow-master/data/sort-of-clevr.100-10.pickle"); PyFile pyFile = new(bufferedInputStream(f)); O o = cPickle.load(pyFile); print("Loaded: " + className(o)); L trainAndTest = cast o; for (L x : (L) trainAndTest) { print(l(x) + " examples"); L entry = cast first(x); print(l(entry)); O img = entry.get(0), relations = entry.get(1), norelations = entry.get(2); print(className(img) + " " + clasName(relations)); } }