{"diffoscope-json-version": 1, "source1": "/srv/reproducible-results/rbuild-debian/r-b-build.nnq3HiUY/b1/python-gsd_2.4.0-1_arm64.changes", "source2": "/srv/reproducible-results/rbuild-debian/r-b-build.nnq3HiUY/b2/python-gsd_2.4.0-1_arm64.changes", "unified_diff": null, "details": [{"source1": "Files", "source2": "Files", "unified_diff": "@@ -1,4 +1,4 @@\n \n- 070df31f32bffc2f7aa2777a85c50837 80356 doc optional python-gsd-doc_2.4.0-1_all.deb\n+ 17dfb7d9359391a2b8976d10dc5d439a 80352 doc optional python-gsd-doc_2.4.0-1_all.deb\n 1592bb4e57d91345392439d8bd8f3132 248556 debug optional python3-gsd-dbgsym_2.4.0-1_arm64.deb\n 22a0f1ef98d8af4be115ec5f2438c876 75056 python optional python3-gsd_2.4.0-1_arm64.deb\n"}, {"source1": "python-gsd-doc_2.4.0-1_all.deb", "source2": "python-gsd-doc_2.4.0-1_all.deb", "unified_diff": null, "details": [{"source1": "file list", "source2": "file list", "unified_diff": "@@ -1,3 +1,3 @@\n -rw-r--r-- 0 0 0 4 2020-12-28 05:06:26.000000 debian-binary\n--rw-r--r-- 0 0 0 2364 2020-12-28 05:06:26.000000 control.tar.xz\n+-rw-r--r-- 0 0 0 2360 2020-12-28 05:06:26.000000 control.tar.xz\n -rw-r--r-- 0 0 0 77800 2020-12-28 05:06:26.000000 data.tar.xz\n"}, {"source1": "control.tar.xz", "source2": "control.tar.xz", "unified_diff": null, "details": [{"source1": "control.tar", "source2": "control.tar", "unified_diff": null, "details": [{"source1": "./md5sums", "source2": "./md5sums", "unified_diff": null, "details": [{"source1": "./md5sums", "source2": "./md5sums", "comments": ["Files differ"], "unified_diff": null}]}]}]}, {"source1": "data.tar.xz", "source2": "data.tar.xz", "unified_diff": null, "details": [{"source1": "data.tar", "source2": "data.tar", "unified_diff": null, "details": [{"source1": "file list", "source2": "file list", "unified_diff": "@@ -59,15 +59,15 @@\n -rw-r--r-- 0 root (0) root (0) 7418 2020-12-28 05:06:26.000000 ./usr/share/doc/python-gsd-doc/html/py-modindex.html\n -rw-r--r-- 0 root (0) root (0) 11468 2020-12-28 05:06:26.000000 ./usr/share/doc/python-gsd-doc/html/python-api.html\n -rw-r--r-- 0 root (0) root (0) 79089 2020-12-28 05:06:26.000000 ./usr/share/doc/python-gsd-doc/html/python-module-gsd.fl.html\n -rw-r--r-- 0 root (0) root (0) 61519 2020-12-28 05:06:26.000000 ./usr/share/doc/python-gsd-doc/html/python-module-gsd.hoomd.html\n -rw-r--r-- 0 root (0) root (0) 31619 2020-12-28 05:06:26.000000 ./usr/share/doc/python-gsd-doc/html/python-module-gsd.pygsd.html\n -rw-r--r-- 0 root (0) root (0) 90606 2020-12-28 05:06:26.000000 ./usr/share/doc/python-gsd-doc/html/schema-hoomd.html\n -rw-r--r-- 0 root (0) root (0) 6318 2020-12-28 05:06:26.000000 ./usr/share/doc/python-gsd-doc/html/search.html\n--rw-r--r-- 0 root (0) root (0) 30368 2020-12-28 05:06:26.000000 ./usr/share/doc/python-gsd-doc/html/searchindex.js\n+-rw-r--r-- 0 root (0) root (0) 30365 2020-12-28 05:06:26.000000 ./usr/share/doc/python-gsd-doc/html/searchindex.js\n -rw-r--r-- 0 root (0) root (0) 23081 2020-12-28 05:06:26.000000 ./usr/share/doc/python-gsd-doc/html/shapes.html\n -rw-r--r-- 0 root (0) root (0) 10386 2020-12-28 05:06:26.000000 ./usr/share/doc/python-gsd-doc/html/specification.html\n -rw-r--r-- 0 root (0) root (0) 14373 2020-12-28 05:06:26.000000 ./usr/share/doc/python-gsd-doc/html/style.html\n drwxr-xr-x 0 root (0) root (0) 0 2020-12-28 05:06:26.000000 ./usr/share/doc-base/\n -rw-r--r-- 0 root (0) root (0) 331 2020-12-28 05:06:26.000000 ./usr/share/doc-base/python-gsd\n lrwxrwxrwx 0 root (0) root (0) 0 2020-12-28 05:06:26.000000 ./usr/share/doc/python-gsd-doc/html/_static/css/badge_only.css -> ../../../../../sphinx_rtd_theme/static/css/badge_only.css\n lrwxrwxrwx 0 root (0) root (0) 0 2020-12-28 05:06:26.000000 ./usr/share/doc/python-gsd-doc/html/_static/css/theme.css -> ../../../../../sphinx_rtd_theme/static/css/theme.css\n"}, {"source1": "./usr/share/doc/python-gsd-doc/html/hoomd-examples.html", "source2": "./usr/share/doc/python-gsd-doc/html/hoomd-examples.html", "unified_diff": "@@ -271,23 +271,23 @@\n Out[15]: 5\n \n In [16]: snap.particles.N\n Out[16]: 9\n \n In [17]: snap.particles.position\n Out[17]: \n-array([[0.5245706 , 0.17691582, 0.89625794],\n- [0.18243265, 0.00196305, 0.6366584 ],\n- [0.5028821 , 0.08704599, 0.6647469 ],\n- [0.2490013 , 0.8141068 , 0.17279822],\n- [0.23064984, 0.26289055, 0.81226426],\n- [0.32249013, 0.45421353, 0.84280944],\n- [0.13356043, 0.87281495, 0.28069597],\n- [0.8240681 , 0.37396756, 0.04699698],\n- [0.3566508 , 0.93444514, 0.19464333]], dtype=float32)\n+array([[0.14993398, 0.2955542 , 0.11552839],\n+ [0.21513675, 0.42452943, 0.34455574],\n+ [0.3940228 , 0.60909444, 0.9184364 ],\n+ [0.8705962 , 0.05873531, 0.41212815],\n+ [0.28900984, 0.64401543, 0.47315508],\n+ [0.40144217, 0.7761984 , 0.23247035],\n+ [0.1513927 , 0.52704567, 0.66262907],\n+ [0.756538 , 0.66026497, 0.50320125],\n+ [0.73057336, 0.7785844 , 0.28817362]], dtype=float32)\n \n \n
gsd.hoomd.HOOMDTrajectory
supports random indexing of frames in the file.\n Indexing into a trajectory returns a gsd.hoomd.Snapshot
.
In [22]: f = gsd.pygsd.GSDFile(open('test.gsd', 'rb'))\n \n In [23]: t = gsd.hoomd.HOOMDTrajectory(f);\n \n In [24]: t[3].particles.position\n Out[24]: \n-array([[0.28240174, 0.06725304, 0.9072712 ],\n- [0.12521122, 0.09689949, 0.19997883],\n- [0.13845731, 0.00118643, 0.22845197],\n- [0.56794554, 0.6146538 , 0.23956142],\n- [0.9118391 , 0.22793762, 0.5929784 ],\n- [0.34945583, 0.590172 , 0.19341233],\n- [0.8181911 , 0.5596076 , 0.14845468]], dtype=float32)\n+array([[0.25202537, 0.34765884, 0.08629612],\n+ [0.47895682, 0.69212115, 0.96801 ],\n+ [0.5350837 , 0.05925987, 0.77409524],\n+ [0.6918647 , 0.48423377, 0.03602023],\n+ [0.6377426 , 0.5760921 , 0.02306124],\n+ [0.6329108 , 0.43502742, 0.91925454],\n+ [0.1706567 , 0.62367386, 0.6459214 ]], dtype=float32)\n
You can use GSD without needing to compile C code to read GSD files\n using gsd.pygsd.GSDFile
in combination with gsd.hoomd.HOOMDTrajectory
. It\n only supports the rb
mode and does not read files as fast as the C\n implementation. It takes in a python file-like object, so it can be used with\n in-memory IO classes, and grid file classes that access data over the internet.