deep-learning-keras-tf-tutorial icon indicating copy to clipboard operation
deep-learning-keras-tf-tutorial copied to clipboard

how can i get the text tag

Open herbiel opened this issue 3 years ago • 3 comments

reviews = [ 'Reply to win £100 weekly! Where will the 2006 FIFA World Cup be held? Send STOP to 87239 to end service', 'You are awarded a SiPix Digital Camera! call 09061221061 from landline. Delivery within 28days. T Cs Box177. M221BP. 2yr warranty. 150ppm. 16 . p p£3.99', 'it to 80488. Your 500 free text messages are valid until 31 December 2005.', 'Hey Sam, Are you coming for a cricket game tomorrow', "Why don't you wait 'til at least wednesday to see if you get your ." ] model.predict(reviews) array([[0.6472808 ], [0.7122627 ], [0.5710311 ], [0.06721176], [0.02479185]], dtype=float32)

can i know what's tag on reviews ?

herbiel avatar Jul 18 '22 09:07 herbiel

if model prediction > 0.5 -> 1:

other situation -> 0:

1 or 0 should equal to spam or ham.

Let's some coding...

bilal-24 avatar Sep 03 '22 09:09 bilal-24

can we make multi-label ,such as 0,1,2,3....

herbiel avatar Sep 03 '22 09:09 herbiel

Ham -> 0 Spam -> 1

That is the binary classification problem. Can you show multi label in this problem?

But in another project, we can use sparse_categorical_crossentropy or categorical_crossentropy and then get multi label predictions.

I think you should watch CodeBasic's CNN videos. He was telling there, you should learn loss functions and label processing.

bilal-24 avatar Sep 05 '22 05:09 bilal-24