Beispiel #1
0
    def serializeWasm(self):
        if (self.isbinary == False):
            return biswasm.serialize_simpledataobject(self.data_array)

        top_header = np.zeros([4], dtype=np.int32)
        top_header[0] = biswasm.getVectorMagicCode()
        top_header[1] = biswasm.get_nifti_code(np.uint8)
        top_header[2] = 0
        top_header[3] = len(self.data_array)
        return top_header.tobytes() + self.data_array
Beispiel #2
0
 def serializeWasm(self):
     return biswasm.serialize_simpledataobject(mat=self.data_array,
                                               spa=self.spacing,
                                               debug=0,
                                               isimage=True)
Beispiel #3
0
 def serializeWasm(self):
     return biswasm.serialize_simpledataobject(self.data_array)