dinsdag 16 april 2019

3 - more NLP

Ok, het model werkt dus maar ik had een iets beter positie op de ranglijst gehoopt. Dan maar een kijken of we e.e.a. kunnen opschroeven.

Dit is de uitgangsnorm: 94.92% val_acc

Epoch 2/20
1443899/1443899 [==============================] - 972s 673us/step - loss: 0.1309 - acc: 0.9518 - val_loss: 0.1399 - val_acc: 0.9492

Eerst maar eens kijken of we de data beter kunnen opschonen. Ik haal mer puntuaties eruit. Laat de einde regel sumbolen staan (vervang door punt) en ook de quotes maak ik eenduidig omdat ik denk dat dat kan helpen bij een tetere interpretatie. Tevens maak ik alles lowercase. Bij een test op de train resultaten scoort hij 3.77% fout. O.a. in dit soort regels:

1 0 these folks and their attorneys are a safety threat to all of society they should stay in jail .  0.04372574
1 0 i advise the feds to follow the money that is given to these anti american religious sovereign terrorists .  0.0523168
1 0 mmmmm you had me at cheap and mediocre .  0.283443
1 0 ltd needs to be neutered .  0.19635834
1 0 you re such a douche . you have no idea what you re talking about .  0.3822083
1 0 this is pretty much exactly how i feel . damn .  0.46514317
1 0 attorneys politicians and preachers doing what they do best .patting themselves and each other on the back .  0.02539003
1 0 i agree with you . obama is inflammatory and disrespectful .  0.019637559
0 1 most of the bums i see downtown won t walk   feet to throw trash in a trash can . these will do no good at all . end needle exchanges and stop giving he employment resistant free needles 0.6297242
0 1 to be fair i hear the same nonsense from the minority over the top hillary supporters . there is no lack of bernie baggers and hillary bots screaming nonsense .  0.532752
1 0 snitch 0.0067454237
1 0 what are supposed to see in the pic . the behind of a guy in a suit . really . ok .  0.02872668
1 0 jp says . " trump is a product of many angry mostly white americans " racist stereotyping duly noted .  0.39688396

  De eerste waarde is de werkelijke classifucatie en de 2e de voorspelde. Achteraan staat de oorsprongkelijke kans.

De aanpassingen leveren helaas niet veel verbeteringen op. Sterker nog we lijken iets achteruit te zijn gegaan:

Epoch 2/5
1443899/1443899 [==============================] - 912s 632us/step - loss: 0.1303 - acc: 0.9520 - val_loss: 0.1402 - val_acc: 0.9490

94.9% val_acc . Maar dat kunnen verschillen in initiatie zijn. Even in de gaten houden.



Geen opmerkingen:

Een reactie posten