二进制与base64 函数使用 def base64_to_image(base64_code): img_data = base64.b64decode(base64_code) img_array = numpy.fromstring(img_data, numpy.uint8) # img_array = np.frombuffer(image_bytes, dtype=np.uint8) #可选 image_base64_dec = c