TypeError: Cannot cast array data from dtype('float64') to dtype('S32') according to the rule 'safe' I'm getting the above error while I'm extracting the sensor data from serial port and giving it for prediction.Tried reshape and string functions but every trial throws back me same error.i'm using mlp neuralnetwork in my model.Thanks in advance
Spent some time with error and found that serial data consists a newline character"\n" in it and it caused error pitch data is a float and due added character roll value is a string.So, changed code as below a little and it worked