Guest User

Untitled

a guest
Jan 20th, 2019
90
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.53 KB | None | 0 0
  1. image1 = Image.open(io.BytesIO(flutter_input))
  2. image = np.array(image1)
  3. // Apply machine learning algorithim
  4. print("Length of image is ", len(image.flatten()))
  5. output = bytes(image)
  6.  
  7. self.sendMessage(our, True)
  8.  
  9. I.Image _img = I.decodeImage(binaryIntList);
  10. _img = I.encodeJpg(_img);
  11.  
  12. IOWebSocketChannel.connect("ws://10.7.4.78:8080");
  13. List<int> imageBytes = img.readAsBytesSync();
  14. channel.sink.add(imageBytes);
  15. channel.stream.listen(( message) {
  16.  
  17. Image im1 =Image.memory(message)};
  18. print(im1.height) // Prints null
Add Comment
Please, Sign In to add comment