def make_qr(data, version=4): qr = pyqrcode.QRCode(data, version=version) text = qr.text(quiet_zone=1) return [map(int, row) for row in text.split()]