Commit 0d270641 authored by Thomas Kluyver's avatar Thomas Kluyver
Browse files

Fix example

parent e8014739
......@@ -4,5 +4,5 @@ from pycrystfel.bindings import Detector
det = Detector.from_filename(sys.argv[1])
print(f"{det.n_panels} panels:")
for name in det.panel_names:
for name in det.panel_names():
print(f"- {name}")
......@@ -105,4 +105,4 @@ cdef class Detector:
return self._ptr.n_panels if self._ptr is not NULL else 0
def panel_names(self):
return [self._ptr.panels[i].name for i in range(self.n_panels)]
return [self._ptr.panels[i].name.decode('utf-8') for i in range(self.n_panels)]
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment