noshot 0.1.7__py3-none-any.whl → 0.1.9__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (239) hide show
  1. noshot/data/ML TS XAI/ML/1. PCA - EDA/PCA-EDA.ipynb +207 -0
  2. noshot/data/ML TS XAI/ML/1. PCA - EDA/balance-scale.csv +626 -0
  3. noshot/data/ML TS XAI/ML/1. PCA - EDA/input.txt +625 -0
  4. noshot/data/ML TS XAI/ML/2. KNN Classifier/KNN.ipynb +287 -0
  5. noshot/data/ML TS XAI/ML/2. KNN Classifier/balance-scale.csv +626 -0
  6. noshot/data/ML TS XAI/ML/2. KNN Classifier/input.txt +625 -0
  7. noshot/data/ML TS XAI/ML/3. Linear Discriminant Analysis/LDA.ipynb +83 -0
  8. noshot/data/ML TS XAI/ML/3. Linear Discriminant Analysis/balance-scale.csv +626 -0
  9. noshot/data/ML TS XAI/ML/3. Linear Discriminant Analysis/input.txt +625 -0
  10. noshot/data/ML TS XAI/ML/4. Linear Regression/Linear-Regression.ipynb +117 -0
  11. noshot/data/ML TS XAI/ML/4. Linear Regression/machine-data.csv +210 -0
  12. noshot/data/ML TS XAI/ML/5. Logistic Regression/Logistic-Regression.ipynb +137 -0
  13. noshot/data/ML TS XAI/ML/5. Logistic Regression/wine-dataset.csv +179 -0
  14. noshot/data/ML TS XAI/ML/6. Bayesian Classifier/Bayesian.ipynb +129 -0
  15. noshot/data/ML TS XAI/ML/6. Bayesian Classifier/wine-dataset.csv +179 -0
  16. noshot/data/ML TS XAI/TS/1. EDA - Handling Time Series Data/Handling TS Data.ipynb +784 -0
  17. noshot/data/ML TS XAI/TS/1. EDA - Handling Time Series Data/raw_sales.csv +29581 -0
  18. noshot/data/ML TS XAI/TS/2. Feature Engineering/Feature Engineering-.ipynb +1445 -0
  19. noshot/data/ML TS XAI/TS/3. Temporal Relationships/Exploring Temporal Relationships.ipynb +603 -0
  20. noshot/data/ML TS XAI/TS/4. Up-Down-Sampling and Interploation/Up-Down-Sampling.ipynb +721 -0
  21. noshot/data/ML TS XAI/TS/4. Up-Down-Sampling and Interploation/shampoo_sales.csv +37 -0
  22. noshot/data/ML TS XAI/TS/5. Stationarity - Trend - Seasonality/Stationarity-Trend-Seasonality.ipynb +392 -0
  23. noshot/data/ML TS XAI/TS/5. Stationarity - Trend - Seasonality/daily-min-temperatures.csv +3651 -0
  24. noshot/data/ML TS XAI/TS/5. Stationarity - Trend - Seasonality/daily-total-female-births.csv +366 -0
  25. noshot/data/ML TS XAI/TS/6. Autocorrelation - Partial Autocorrelation/ACF-PACF.ipynb +175 -0
  26. noshot/data/ML TS XAI/TS/6. Autocorrelation - Partial Autocorrelation/daily-min-temperatures.csv +3651 -0
  27. {noshot-0.1.7.dist-info → noshot-0.1.9.dist-info}/METADATA +2 -2
  28. noshot-0.1.9.dist-info/RECORD +35 -0
  29. noshot/data/ML TS XAI/AIDS/1. Implement Basic Search Strategies/(A) Breadth First Search.ipynb +0 -112
  30. noshot/data/ML TS XAI/AIDS/1. Implement Basic Search Strategies/(B) Depth First Search.ipynb +0 -111
  31. noshot/data/ML TS XAI/AIDS/1. Implement Basic Search Strategies/(C) Uniform Cost Search.ipynb +0 -134
  32. noshot/data/ML TS XAI/AIDS/1. Implement Basic Search Strategies/(D) Depth Limites Search.ipynb +0 -115
  33. noshot/data/ML TS XAI/AIDS/1. Implement Basic Search Strategies/(E) Iterative Deepening DFS.ipynb +0 -123
  34. noshot/data/ML TS XAI/AIDS/10. ANOVA/2_ANOVA.csv +0 -769
  35. noshot/data/ML TS XAI/AIDS/10. ANOVA/One Way ANOVA (Repeated Measure).ipynb +0 -126
  36. noshot/data/ML TS XAI/AIDS/10. ANOVA/One Way ANOVA.ipynb +0 -134
  37. noshot/data/ML TS XAI/AIDS/10. ANOVA/Sample 1 Way ANOVA Test.ipynb +0 -119
  38. noshot/data/ML TS XAI/AIDS/10. ANOVA/Two Way ANOVA.ipynb +0 -138
  39. noshot/data/ML TS XAI/AIDS/10. ANOVA/reaction_time.csv +0 -5
  40. noshot/data/ML TS XAI/AIDS/10. ANOVA/sample_data.csv +0 -16
  41. noshot/data/ML TS XAI/AIDS/10. ANOVA/sleep_deprivation.csv +0 -4
  42. noshot/data/ML TS XAI/AIDS/11. Linear Regression/3_Linear.csv +0 -4802
  43. noshot/data/ML TS XAI/AIDS/11. Linear Regression/Linear Regression LAB.ipynb +0 -113
  44. noshot/data/ML TS XAI/AIDS/11. Linear Regression/Linear Regression New- sklearn.ipynb +0 -118
  45. noshot/data/ML TS XAI/AIDS/11. Linear Regression/Linear Regression.ipynb +0 -148
  46. noshot/data/ML TS XAI/AIDS/11. Linear Regression/house_rate.csv +0 -22
  47. noshot/data/ML TS XAI/AIDS/12. Logistic Regression/Logistic Regression New- sklearn.ipynb +0 -128
  48. noshot/data/ML TS XAI/AIDS/12. Logistic Regression/Logistic Regression.ipynb +0 -145
  49. noshot/data/ML TS XAI/AIDS/12. Logistic Regression/default.csv +0 -1001
  50. noshot/data/ML TS XAI/AIDS/12. Logistic Regression/hours_scores_records.csv +0 -101
  51. noshot/data/ML TS XAI/AIDS/2. Implement A Star And MA Star/(A) Astar.ipynb +0 -256
  52. noshot/data/ML TS XAI/AIDS/2. Implement A Star And MA Star/(B) IDAstar.ipynb +0 -157
  53. noshot/data/ML TS XAI/AIDS/2. Implement A Star And MA Star/(C) SMAstar.ipynb +0 -178
  54. noshot/data/ML TS XAI/AIDS/3. Genetic Algorithm/Genetic.ipynb +0 -95
  55. noshot/data/ML TS XAI/AIDS/4. Simulated Annealing/Simulated Annealing.ipynb +0 -74
  56. noshot/data/ML TS XAI/AIDS/4. Simulated Annealing/Sudoku Simulated Annealing.ipynb +0 -103
  57. noshot/data/ML TS XAI/AIDS/5. Alpha Beta Pruning/AlphaBetaPruning.ipynb +0 -182
  58. noshot/data/ML TS XAI/AIDS/6. Consraint Satisfaction Problems (CSP)/(A) CSP House Allocation.ipynb +0 -120
  59. noshot/data/ML TS XAI/AIDS/6. Consraint Satisfaction Problems (CSP)/(B) CSP Map Coloring.ipynb +0 -125
  60. noshot/data/ML TS XAI/AIDS/7. Random Sampling/Random Sampling.ipynb +0 -73
  61. noshot/data/ML TS XAI/AIDS/7. Random Sampling/height_weight_bmi.csv +0 -8389
  62. noshot/data/ML TS XAI/AIDS/8. Z Test/Z Test Hash Function.ipynb +0 -141
  63. noshot/data/ML TS XAI/AIDS/8. Z Test/Z Test.ipynb +0 -151
  64. noshot/data/ML TS XAI/AIDS/8. Z Test/height_weight_bmi.csv +0 -8389
  65. noshot/data/ML TS XAI/AIDS/9. T Test/1_heart.csv +0 -304
  66. noshot/data/ML TS XAI/AIDS/9. T Test/Independent T Test.ipynb +0 -119
  67. noshot/data/ML TS XAI/AIDS/9. T Test/Paired T Test.ipynb +0 -118
  68. noshot/data/ML TS XAI/AIDS/9. T Test/T Test Hash Function.ipynb +0 -142
  69. noshot/data/ML TS XAI/AIDS/9. T Test/T Test.ipynb +0 -158
  70. noshot/data/ML TS XAI/AIDS/9. T Test/height_weight_bmi.csv +0 -8389
  71. noshot/data/ML TS XAI/AIDS/9. T Test/iq_test.csv +0 -0
  72. noshot/data/ML TS XAI/AIDS/Others (AllinOne)/All In One.ipynb +0 -4581
  73. noshot/data/ML TS XAI/CN/1. Chat Application/chat.java +0 -81
  74. noshot/data/ML TS XAI/CN/1. Chat Application/output.png +0 -0
  75. noshot/data/ML TS XAI/CN/1. Chat Application/procedure.png +0 -0
  76. noshot/data/ML TS XAI/CN/10. Ethernet LAN IEEE 802.3/LAN.tcl +0 -65
  77. noshot/data/ML TS XAI/CN/10. Ethernet LAN IEEE 802.3/analysis.awk +0 -44
  78. noshot/data/ML TS XAI/CN/10. Ethernet LAN IEEE 802.3/output.png +0 -0
  79. noshot/data/ML TS XAI/CN/10. Ethernet LAN IEEE 802.3/procedure.png +0 -0
  80. noshot/data/ML TS XAI/CN/11. Wireless LAN IEEE 802.11/complexdcf.tcl +0 -229
  81. noshot/data/ML TS XAI/CN/11. Wireless LAN IEEE 802.11/output.png +0 -0
  82. noshot/data/ML TS XAI/CN/11. Wireless LAN IEEE 802.11/procedure.png +0 -0
  83. noshot/data/ML TS XAI/CN/2. File Transfer/file_to_send.txt +0 -2
  84. noshot/data/ML TS XAI/CN/2. File Transfer/filetransfer.java +0 -119
  85. noshot/data/ML TS XAI/CN/2. File Transfer/output.png +0 -0
  86. noshot/data/ML TS XAI/CN/2. File Transfer/procedure.png +0 -0
  87. noshot/data/ML TS XAI/CN/3. RMI (Remote Method Invocation)/Client.class +0 -0
  88. noshot/data/ML TS XAI/CN/3. RMI (Remote Method Invocation)/MyServerImpl.class +0 -0
  89. noshot/data/ML TS XAI/CN/3. RMI (Remote Method Invocation)/MyServerIntf.class +0 -0
  90. noshot/data/ML TS XAI/CN/3. RMI (Remote Method Invocation)/Server.class +0 -0
  91. noshot/data/ML TS XAI/CN/3. RMI (Remote Method Invocation)/output.png +0 -0
  92. noshot/data/ML TS XAI/CN/3. RMI (Remote Method Invocation)/procedure.png +0 -0
  93. noshot/data/ML TS XAI/CN/3. RMI (Remote Method Invocation)/rmi.java +0 -56
  94. noshot/data/ML TS XAI/CN/4. Wired Network/output.png +0 -0
  95. noshot/data/ML TS XAI/CN/4. Wired Network/procedure.png +0 -0
  96. noshot/data/ML TS XAI/CN/4. Wired Network/wired.awk +0 -25
  97. noshot/data/ML TS XAI/CN/4. Wired Network/wired.tcl +0 -81
  98. noshot/data/ML TS XAI/CN/5. Wireless Network/output.png +0 -0
  99. noshot/data/ML TS XAI/CN/5. Wireless Network/procedure.png +0 -0
  100. noshot/data/ML TS XAI/CN/5. Wireless Network/wireless.awk +0 -27
  101. noshot/data/ML TS XAI/CN/5. Wireless Network/wireless.tcl +0 -153
  102. noshot/data/ML TS XAI/CN/6. TCP Flow And Congestion Control/TCP Congestion Control/Sack And Vegas/analysis.awk +0 -27
  103. noshot/data/ML TS XAI/CN/6. TCP Flow And Congestion Control/TCP Congestion Control/Sack And Vegas/output.png +0 -0
  104. noshot/data/ML TS XAI/CN/6. TCP Flow And Congestion Control/TCP Congestion Control/Sack And Vegas/sack.tcl +0 -86
  105. noshot/data/ML TS XAI/CN/6. TCP Flow And Congestion Control/TCP Congestion Control/Sack And Vegas/vegas.tcl +0 -86
  106. noshot/data/ML TS XAI/CN/6. TCP Flow And Congestion Control/TCP Congestion Control/Tahoe And Reno/analysis.awk +0 -28
  107. noshot/data/ML TS XAI/CN/6. TCP Flow And Congestion Control/TCP Congestion Control/Tahoe And Reno/output.png +0 -0
  108. noshot/data/ML TS XAI/CN/6. TCP Flow And Congestion Control/TCP Congestion Control/Tahoe And Reno/reno.tcl +0 -78
  109. noshot/data/ML TS XAI/CN/6. TCP Flow And Congestion Control/TCP Congestion Control/Tahoe And Reno/tahoe.tcl +0 -79
  110. noshot/data/ML TS XAI/CN/6. TCP Flow And Congestion Control/TCP Flow Control/analysis.awk +0 -27
  111. noshot/data/ML TS XAI/CN/6. TCP Flow And Congestion Control/TCP Flow Control/flow.tcl +0 -163
  112. noshot/data/ML TS XAI/CN/6. TCP Flow And Congestion Control/TCP Flow Control/output.png +0 -0
  113. noshot/data/ML TS XAI/CN/6. TCP Flow And Congestion Control/procedure.png +0 -0
  114. noshot/data/ML TS XAI/CN/7. Link State And Distance Vector Routing/DV.tcl +0 -111
  115. noshot/data/ML TS XAI/CN/7. Link State And Distance Vector Routing/LS.tcl +0 -106
  116. noshot/data/ML TS XAI/CN/7. Link State And Distance Vector Routing/analysis.awk +0 -36
  117. noshot/data/ML TS XAI/CN/7. Link State And Distance Vector Routing/output.png +0 -0
  118. noshot/data/ML TS XAI/CN/7. Link State And Distance Vector Routing/procedure.png +0 -0
  119. noshot/data/ML TS XAI/CN/8. Multicast And Broadcast Routing/analysis.awk +0 -20
  120. noshot/data/ML TS XAI/CN/8. Multicast And Broadcast Routing/broadcast.tcl +0 -76
  121. noshot/data/ML TS XAI/CN/8. Multicast And Broadcast Routing/multicast.tcl +0 -103
  122. noshot/data/ML TS XAI/CN/8. Multicast And Broadcast Routing/output.png +0 -0
  123. noshot/data/ML TS XAI/CN/8. Multicast And Broadcast Routing/procedure.png +0 -0
  124. noshot/data/ML TS XAI/CN/9. DHCP/DHCP.java +0 -125
  125. noshot/data/ML TS XAI/CN/9. DHCP/output.png +0 -0
  126. noshot/data/ML TS XAI/CN/9. DHCP/procedure.png +0 -0
  127. noshot/data/ML TS XAI/NLP/NLP 1/1-Prereqs.py +0 -18
  128. noshot/data/ML TS XAI/NLP/NLP 1/2-Chi2test.py +0 -83
  129. noshot/data/ML TS XAI/NLP/NLP 1/2-T-test.py +0 -79
  130. noshot/data/ML TS XAI/NLP/NLP 1/3-WSD-nb.py +0 -53
  131. noshot/data/ML TS XAI/NLP/NLP 1/4-Hindle-Rooth.py +0 -53
  132. noshot/data/ML TS XAI/NLP/NLP 1/5-HMM-Trellis.py +0 -82
  133. noshot/data/ML TS XAI/NLP/NLP 1/6-HMM-Viterbi.py +0 -16
  134. noshot/data/ML TS XAI/NLP/NLP 1/7-PCFG-parsetree.py +0 -15
  135. noshot/data/ML TS XAI/NLP/NLP 1/Chi2test.ipynb +0 -285
  136. noshot/data/ML TS XAI/NLP/NLP 1/Hindle-Rooth.ipynb +0 -179
  137. noshot/data/ML TS XAI/NLP/NLP 1/Lab 10 - Text generator using LSTM.ipynb +0 -1461
  138. noshot/data/ML TS XAI/NLP/NLP 1/Lab 11 NMT.ipynb +0 -2307
  139. noshot/data/ML TS XAI/NLP/NLP 1/PCFG.ipynb +0 -134
  140. noshot/data/ML TS XAI/NLP/NLP 1/Prereqs.ipynb +0 -131
  141. noshot/data/ML TS XAI/NLP/NLP 1/T test.ipynb +0 -252
  142. noshot/data/ML TS XAI/NLP/NLP 1/TFIDF BOW.ipynb +0 -171
  143. noshot/data/ML TS XAI/NLP/NLP 1/Trellis.ipynb +0 -244
  144. noshot/data/ML TS XAI/NLP/NLP 1/WSD.ipynb +0 -645
  145. noshot/data/ML TS XAI/NLP/NLP 1/Word2Vec.ipynb +0 -93
  146. noshot/data/ML TS XAI/NLP/NLP 2/Lab01(tokenizer)/tokenizer.ipynb +0 -370
  147. noshot/data/ML TS XAI/NLP/NLP 2/Lab01(tokenizer)/training_tokenizer.txt +0 -6
  148. noshot/data/ML TS XAI/NLP/NLP 2/Lab02(stemming)/exp0.ipynb +0 -274
  149. noshot/data/ML TS XAI/NLP/NLP 2/Lab02(stemming)/lab2.ipynb +0 -905
  150. noshot/data/ML TS XAI/NLP/NLP 2/Lab02(stemming)/test.txt +0 -1
  151. noshot/data/ML TS XAI/NLP/NLP 2/Lab02(stemming)/tokenizing.ipynb +0 -272
  152. noshot/data/ML TS XAI/NLP/NLP 2/Lab03(parse-tree)/collocation.ipynb +0 -332
  153. noshot/data/ML TS XAI/NLP/NLP 2/Lab03(parse-tree)/lab3.ipynb +0 -549
  154. noshot/data/ML TS XAI/NLP/NLP 2/Lab03(parse-tree)/nlp.txt +0 -1
  155. noshot/data/ML TS XAI/NLP/NLP 2/Lab04(collocation)/Lab4-NLP-Exp-2.ipynb +0 -817
  156. noshot/data/ML TS XAI/NLP/NLP 2/Lab04(collocation)/collocation.ipynb +0 -332
  157. noshot/data/ML TS XAI/NLP/NLP 2/Lab05(WSD)/NLP-Lab-5-Exp3.ipynb +0 -231
  158. noshot/data/ML TS XAI/NLP/NLP 2/Lab05(WSD)/word-sense-disambiguation.ipynb +0 -507
  159. noshot/data/ML TS XAI/NLP/NLP 2/Lab06(additional-exercise)/lab6.ipynb +0 -134
  160. noshot/data/ML TS XAI/NLP/NLP 2/Lab07(HMM,Viterbi)/NLP Exp 4.ipynb +0 -255
  161. noshot/data/ML TS XAI/NLP/NLP 2/Lab07(HMM,Viterbi)/NLP_Exp_5.ipynb +0 -159
  162. noshot/data/ML TS XAI/NLP/NLP 2/Lab08(PCFG)/PCFG.ipynb +0 -282
  163. noshot/data/ML TS XAI/NLP/NLP 2/Lab09-Hindle-rooth&MLP/Lab 9 - MLP classifier.ipynb +0 -670
  164. noshot/data/ML TS XAI/NLP/NLP 2/Lab09-Hindle-rooth&MLP/MLP-alternative-code.ipynb +0 -613
  165. noshot/data/ML TS XAI/NLP/NLP 2/Lab09-Hindle-rooth&MLP/hindle-rooth-algorithm.ipynb +0 -74
  166. noshot/data/ML TS XAI/NLP/NLP 2/Lab10(LSTM)/Lab_10_Text_generator_using_LSTM.ipynb +0 -480
  167. noshot/data/ML TS XAI/NLP/NLP 2/Lab11(Viterbi-PCFG,Machine-translation)/Machine-translation.ipynb +0 -445
  168. noshot/data/ML TS XAI/NLP/NLP 2/Lab11(Viterbi-PCFG,Machine-translation)/Viterbi-PCFG.ipynb +0 -105
  169. noshot/data/ML TS XAI/NLP/NLP 2/Lab11(Viterbi-PCFG,Machine-translation)/corpora_tools.py +0 -87
  170. noshot/data/ML TS XAI/NLP/NLP 2/Lab11(Viterbi-PCFG,Machine-translation)/data_utils.py +0 -11
  171. noshot/data/ML TS XAI/NLP/NLP 2/Lab11(Viterbi-PCFG,Machine-translation)/train_translator.py +0 -83
  172. noshot/data/ML TS XAI/NLP/NLP 2/Lab12(Information-Extraction)/Information_Extraction.ipynb +0 -201
  173. noshot/data/ML TS XAI/NLP/NLP 3/Backtrack-without-Verbitri.ipynb +0 -185
  174. noshot/data/ML TS XAI/NLP/NLP 3/Backward-Procedure.ipynb +0 -597
  175. noshot/data/ML TS XAI/NLP/NLP 3/Bag_of.ipynb +0 -1422
  176. noshot/data/ML TS XAI/NLP/NLP 3/CYK-algorithm.ipynb +0 -1067
  177. noshot/data/ML TS XAI/NLP/NLP 3/Forward-Procedure.ipynb +0 -477
  178. noshot/data/ML TS XAI/NLP/NLP 3/LSTM.ipynb +0 -1290
  179. noshot/data/ML TS XAI/NLP/NLP 3/Lab 10 - Text generator using LSTM.ipynb +0 -1461
  180. noshot/data/ML TS XAI/NLP/NLP 3/Lab 11 NMT.ipynb +0 -2307
  181. noshot/data/ML TS XAI/NLP/NLP 3/NLP-LAB-4.ipynb +0 -216
  182. noshot/data/ML TS XAI/NLP/NLP 3/NLP-LAB-5.ipynb +0 -216
  183. noshot/data/ML TS XAI/NLP/NLP 3/abc.txt +0 -6
  184. noshot/data/ML TS XAI/NLP/NLP 3/ex-1-nltk.ipynb +0 -711
  185. noshot/data/ML TS XAI/NLP/NLP 3/ex-2-nlp.ipynb +0 -267
  186. noshot/data/ML TS XAI/NLP/NLP 3/exp8&9.ipynb +0 -305
  187. noshot/data/ML TS XAI/NLP/NLP 3/hind.ipynb +0 -287
  188. noshot/data/ML TS XAI/NLP/NLP 3/lab66.ipynb +0 -752
  189. noshot/data/ML TS XAI/NLP/NLP 3/leb_3.ipynb +0 -612
  190. noshot/data/ML TS XAI/NLP/NLP 3/naive_bayes_classifier.pkl +0 -0
  191. noshot/data/ML TS XAI/NLP/NLP 3/nlp_leb_1.ipynb +0 -3008
  192. noshot/data/ML TS XAI/NLP/NLP 3/nlp_leb_2.ipynb +0 -3095
  193. noshot/data/ML TS XAI/NLP/NLP 3/nlplab-9.ipynb +0 -295
  194. noshot/data/ML TS XAI/NLP/NLP 3/nltk-ex-4.ipynb +0 -506
  195. noshot/data/ML TS XAI/NLP/NLP 3/text1.txt +0 -48
  196. noshot/data/ML TS XAI/NLP/NLP 3/text2.txt +0 -8
  197. noshot/data/ML TS XAI/NLP/NLP 3/text3.txt +0 -48
  198. noshot/data/ML TS XAI/NLP/NLP 3/translation-rnn.ipynb +0 -812
  199. noshot/data/ML TS XAI/NLP/NLP 3/word2vector.ipynb +0 -173
  200. noshot/data/ML TS XAI/NLP/NLP 4/Backward Procedure Algorithm.ipynb +0 -179
  201. noshot/data/ML TS XAI/NLP/NLP 4/Chi Square Collocation.ipynb +0 -208
  202. noshot/data/ML TS XAI/NLP/NLP 4/Collocation (T test).ipynb +0 -188
  203. noshot/data/ML TS XAI/NLP/NLP 4/Experiment 1.ipynb +0 -437
  204. noshot/data/ML TS XAI/NLP/NLP 4/Forward Procedure Algorithm.ipynb +0 -132
  205. noshot/data/ML TS XAI/NLP/NLP 4/Hindle Rooth.ipynb +0 -414
  206. noshot/data/ML TS XAI/NLP/NLP 4/MachineTranslation.ipynb +0 -368
  207. noshot/data/ML TS XAI/NLP/NLP 4/Multi Layer Perceptron using MLPClassifier.ipynb +0 -86
  208. noshot/data/ML TS XAI/NLP/NLP 4/Multi Layer Perceptron using Tensorflow.ipynb +0 -112
  209. noshot/data/ML TS XAI/NLP/NLP 4/PCFG Inside Probability.ipynb +0 -451
  210. noshot/data/ML TS XAI/NLP/NLP 4/Text Generation using LSTM.ipynb +0 -297
  211. noshot/data/ML TS XAI/NLP/NLP 4/Viterbi.ipynb +0 -310
  212. noshot/data/ML TS XAI/NLP/NLP 4/Word Sense Disambiguation.ipynb +0 -335
  213. noshot/data/ML TS XAI/NLP/NLP 5/10.Text Generation using LSTM.ipynb +0 -316
  214. noshot/data/ML TS XAI/NLP/NLP 5/11.Machine Translation.ipynb +0 -868
  215. noshot/data/ML TS XAI/NLP/NLP 5/2.T and Chi2 Test.ipynb +0 -204
  216. noshot/data/ML TS XAI/NLP/NLP 5/3.Word Sense Diambiguation.ipynb +0 -234
  217. noshot/data/ML TS XAI/NLP/NLP 5/4.Hinddle and Rooth.ipynb +0 -128
  218. noshot/data/ML TS XAI/NLP/NLP 5/5.Forward and Backward.ipynb +0 -149
  219. noshot/data/ML TS XAI/NLP/NLP 5/6.Viterbi.ipynb +0 -111
  220. noshot/data/ML TS XAI/NLP/NLP 5/7.PCFG Parse Tree.ipynb +0 -134
  221. noshot/data/ML TS XAI/NLP/NLP 5/7.PCFG using cyk.ipynb +0 -101
  222. noshot/data/ML TS XAI/NLP/NLP 5/8.Bag of words and TF-IDF.ipynb +0 -310
  223. noshot/data/ML TS XAI/NLP/NLP 5/9.Word2Vector.ipynb +0 -78
  224. noshot/data/ML TS XAI/NLP/NLP 5/NLP ALL In One.ipynb +0 -2619
  225. noshot/data/ML TS XAI/NLP/NLP 5/sample1.txt +0 -15
  226. noshot/data/ML TS XAI/NLP/NLP 5/sample2.txt +0 -4
  227. noshot/data/ML TS XAI/NLP/NLP 5/word2vec_model.bin +0 -0
  228. noshot/data/ML TS XAI/NLP/NLP 6/1. Tokenize, Tagging, NER, Parse Tree.ipynb +0 -312
  229. noshot/data/ML TS XAI/NLP/NLP 6/2. T Test and Chi2 Test.ipynb +0 -185
  230. noshot/data/ML TS XAI/NLP/NLP 6/3. Naive Bayes WSD.ipynb +0 -199
  231. noshot/data/ML TS XAI/NLP/NLP 6/4. Hinddle and Rooth.ipynb +0 -151
  232. noshot/data/ML TS XAI/NLP/NLP 6/5 and 6 FWD, BWD, Viterbi.ipynb +0 -164
  233. noshot/data/ML TS XAI/NLP/NLP 6/7. PCFG using CYK.ipynb +0 -383
  234. noshot/data/ML TS XAI/NLP/NLP 6/8. BOW and TF-IDF.ipynb +0 -252
  235. noshot/data/ML TS XAI/Ubuntu CN Lab.iso +0 -0
  236. noshot-0.1.7.dist-info/RECORD +0 -216
  237. {noshot-0.1.7.dist-info → noshot-0.1.9.dist-info}/LICENSE.txt +0 -0
  238. {noshot-0.1.7.dist-info → noshot-0.1.9.dist-info}/WHEEL +0 -0
  239. {noshot-0.1.7.dist-info → noshot-0.1.9.dist-info}/top_level.txt +0 -0
@@ -1,2619 +0,0 @@
1
- {
2
- "cells": [
3
- {
4
- "cell_type": "markdown",
5
- "id": "54b02567-52fb-42d4-8275-0f7aba99e5f9",
6
- "metadata": {},
7
- "source": [
8
- "# __NLP Lab__"
9
- ]
10
- },
11
- {
12
- "cell_type": "markdown",
13
- "id": "88e9ecb1-e6a9-4558-adab-78b033f5a356",
14
- "metadata": {},
15
- "source": [
16
- "<hr style=\"height:10px;border-width:0;background-color:teal\">"
17
- ]
18
- },
19
- {
20
- "cell_type": "markdown",
21
- "id": "8f900daa-14c8-433c-8cfc-bf5b30c768ec",
22
- "metadata": {
23
- "jp-MarkdownHeadingCollapsed": true
24
- },
25
- "source": [
26
- "## __Prerequisite__"
27
- ]
28
- },
29
- {
30
- "cell_type": "markdown",
31
- "id": "bc0595d2-7e73-4dd3-8cef-26fdf9245ea2",
32
- "metadata": {
33
- "jp-MarkdownHeadingCollapsed": true
34
- },
35
- "source": [
36
- "### __Required Libraries__"
37
- ]
38
- },
39
- {
40
- "cell_type": "code",
41
- "execution_count": 1,
42
- "id": "518240b2-680a-41ca-afee-400b36a6ac10",
43
- "metadata": {},
44
- "outputs": [],
45
- "source": [
46
- "import warnings\n",
47
- "warnings.filterwarnings('ignore')"
48
- ]
49
- },
50
- {
51
- "cell_type": "code",
52
- "execution_count": 2,
53
- "id": "d44f95da-e3e2-415a-83c9-ca1d23807a90",
54
- "metadata": {},
55
- "outputs": [
56
- {
57
- "name": "stdout",
58
- "output_type": "stream",
59
- "text": [
60
- "Note: you may need to restart the kernel to use updated packages.\n"
61
- ]
62
- }
63
- ],
64
- "source": [
65
- "pip -q install numpy==1.26.4 pandas==2.2.2 nltk==3.8.1 confusion_matrix==0.1 scipy==1.12.0 xlrd==2.0.1 tensorflow==2.16.1 Keras-Preprocessing==1.1.2 keras==3.6.0 matplotlib scikit-learn-1.5.2 seaborn gensim==4.3.3"
66
- ]
67
- },
68
- {
69
- "cell_type": "markdown",
70
- "id": "456897bb-e569-4bdb-b466-3d1b2582aa09",
71
- "metadata": {},
72
- "source": [
73
- "<hr style=\"height:10px;border-width:0;background-color:teal\">"
74
- ]
75
- },
76
- {
77
- "cell_type": "markdown",
78
- "id": "c2ddc179-44a0-44e1-a8af-1727d91df28f",
79
- "metadata": {
80
- "jp-MarkdownHeadingCollapsed": true
81
- },
82
- "source": [
83
- "### __Loading Documents From Drive__"
84
- ]
85
- },
86
- {
87
- "cell_type": "code",
88
- "execution_count": 3,
89
- "id": "9551fd59-fc33-4dbf-aaf0-216d862d76e5",
90
- "metadata": {},
91
- "outputs": [],
92
- "source": [
93
- "text1 = \"\"\"### The Impact of Social Media on Modern Communication\\n\n",
94
- "In the digital age, social media has revolutionized the way people communicate, offering unprecedented access to information and creating new ways to interact. Platforms like Facebook, Twitter, Instagram, and TikTok have connected individuals from across the globe, allowing for the instant exchange of ideas, images, and experiences. However, the rise of social media has also raised significant concerns about its impact on human relationships, mental health, and societal dynamics. This essay explores the positive and negative effects of social media on modern communication.\\n\n",
95
- "On the positive side, social media has made communication more convenient and accessible than ever before. In the past, staying in touch with friends and family required physical mail, phone calls, or face-to-face interactions. Now, platforms like Facebook and WhatsApp allow people to send messages, share updates, and make video calls at any time, from anywhere in the world. This has facilitated long-distance relationships, strengthened bonds among friends and family, and made it easier to stay connected with people who may otherwise be difficult to reach.\\n\n",
96
- "Moreover, social media has democratized communication, allowing individuals to express their opinions and ideas to a global audience. This has had a profound effect on activism and social movements. For example, platforms like Twitter and Instagram have played crucial roles in raising awareness about issues such as climate change, racial injustice, and political corruption. Activists can mobilize support, organize protests, and share important information in real time. The viral nature of social media also means that messages can reach millions of people in a matter of hours, making it an invaluable tool for social change.\\n\n",
97
- "However, social media's influence is not entirely positive. One of the primary concerns is the effect it has on face-to-face communication skills. As people spend more time interacting online, they may become less adept at having meaningful in-person conversations. Social media interactions tend to be more superficial, with users often relying on emojis, likes, or short messages rather than engaging in deep, thoughtful discussions. This can result in a decline in the quality of personal relationships, as online communication often lacks the nuances and emotional depth found in face-to-face conversations.\\n\n",
98
- "Another issue is the impact of social media on mental health. Studies have shown that excessive use of platforms like Instagram and Facebook can lead to feelings of isolation, anxiety, and depression. Constant comparison to others, especially when viewing curated, idealized images of other people's lives, can lead to low self-esteem and body image issues. The pressure to present a perfect life online, coupled with the fear of missing out (FOMO), can also contribute to heightened stress and dissatisfaction. Additionally, cyberbullying and online harassment have become increasingly prevalent, leading to harmful consequences for individuals, particularly teenagers.\\n\n",
99
- "Furthermore, social media can exacerbate the spread of misinformation. Fake news, conspiracy theories, and misleading content can spread rapidly across platforms, influencing public opinion and distorting perceptions of reality. The algorithms that govern social media platforms often prioritize content that generates engagement, meaning sensational or controversial material is more likely to be shared and seen by a wide audience. This can create echo chambers where individuals are exposed only to information that confirms their existing beliefs, reinforcing polarization and division in society.\\n\n",
100
- "In conclusion, social media has undeniably transformed modern communication, making it easier to connect with others and share information on a global scale. However, its impact on face-to-face interactions, mental health, and the spread of misinformation presents significant challenges. As social media continues to evolve, it is crucial that users and society as a whole strike a balance, using these platforms in ways that enhance communication while minimizing their negative effects.\"\"\"\n",
101
- "\n",
102
- "text2 = \"\"\"chair put coat, back Furniture\n",
103
- "chair IT department Furniture\n",
104
- "where here put chair Furniture\n",
105
- "CSE chair head Position\"\"\"\n",
106
- "\n",
107
- "with open('sample1.txt', 'w') as f1:\n",
108
- " f1.write(text1)\n",
109
- "with open('sample2.txt', 'w') as f2:\n",
110
- " f2.write(text2)"
111
- ]
112
- },
113
- {
114
- "cell_type": "code",
115
- "execution_count": 4,
116
- "id": "77b6f276-e07e-49cc-9a74-f9382d5f29a9",
117
- "metadata": {},
118
- "outputs": [],
119
- "source": [
120
- "import pandas as pd\n",
121
- "url3 = \"https://drive.google.com/uc?export=download&id=1_yRTLQSinbp-ePnUyLVpbRMUDBceRbMU\" #data.csv\n",
122
- "pd.read_csv(url3).to_csv('data.csv', index = False)"
123
- ]
124
- },
125
- {
126
- "cell_type": "markdown",
127
- "id": "9cef5b55-9562-4cc2-81b7-cd2f6bd8af3a",
128
- "metadata": {},
129
- "source": [
130
- "<hr style=\"height:10px;border-width:0;background-color:teal\">"
131
- ]
132
- },
133
- {
134
- "cell_type": "markdown",
135
- "id": "5c1703ec-42f3-4023-9c71-b3f46587ea79",
136
- "metadata": {},
137
- "source": [
138
- "# __2.Implement t-Test and Chi-Square test to check whether a given sequence of words is a collocation or not.__"
139
- ]
140
- },
141
- {
142
- "cell_type": "code",
143
- "execution_count": 5,
144
- "id": "fbde4a26-a923-4b2a-a20a-5010ae791ff0",
145
- "metadata": {},
146
- "outputs": [
147
- {
148
- "name": "stderr",
149
- "output_type": "stream",
150
- "text": [
151
- "[nltk_data] Downloading package stopwords to\n",
152
- "[nltk_data] C:\\Users\\sugan\\AppData\\Roaming\\nltk_data...\n",
153
- "[nltk_data] Package stopwords is already up-to-date!\n",
154
- "[nltk_data] Downloading package punkt to\n",
155
- "[nltk_data] C:\\Users\\sugan\\AppData\\Roaming\\nltk_data...\n",
156
- "[nltk_data] Package punkt is already up-to-date!\n"
157
- ]
158
- },
159
- {
160
- "data": {
161
- "text/plain": [
162
- "True"
163
- ]
164
- },
165
- "execution_count": 5,
166
- "metadata": {},
167
- "output_type": "execute_result"
168
- }
169
- ],
170
- "source": [
171
- "import nltk\n",
172
- "nltk.download('stopwords')\n",
173
- "nltk.download('punkt')"
174
- ]
175
- },
176
- {
177
- "cell_type": "code",
178
- "execution_count": 6,
179
- "id": "80964614-3a9a-4ec4-8765-08c2ad506753",
180
- "metadata": {},
181
- "outputs": [
182
- {
183
- "name": "stdout",
184
- "output_type": "stream",
185
- "text": [
186
- "['#', '#', '#', 'The', 'Impact', 'of', 'Social', 'Media', 'on', 'Modern', 'Communication', 'In', 'the', 'digital', 'age', ',', 'social', 'media', 'has', 'revolutionized', 'the', 'way', 'people', 'communicate', ',', 'offering', 'unprecedented', 'access', 'to', 'information', 'and', 'creating', 'new', 'ways', 'to', 'interact', '.', 'Platforms', 'like', 'Facebook', ',', 'Twitter', ',', 'Instagram', ',', 'and', 'TikTok', 'have', 'connected', 'individuals', 'from', 'across', 'the', 'globe', ',', 'allowing', 'for', 'the', 'instant', 'exchange', 'of', 'ideas', ',', 'images', ',', 'and', 'experiences', '.', 'However', ',', 'the', 'rise', 'of', 'social', 'media', 'has', 'also', 'raised', 'significant', 'concerns', 'about', 'its', 'impact', 'on', 'human', 'relationships', ',', 'mental', 'health', ',', 'and', 'societal', 'dynamics', '.', 'This', 'essay', 'explores', 'the', 'positive', 'and']\n"
187
- ]
188
- }
189
- ],
190
- "source": [
191
- "from nltk.corpus import stopwords\n",
192
- "from nltk.tokenize import word_tokenize\n",
193
- "\n",
194
- "f=open(\"sample1.txt\",\"r\")\n",
195
- "text=f.read()\n",
196
- "\n",
197
- "stop_words = set(stopwords.words(\"english\"))\n",
198
- "word_tokens = word_tokenize(text)\n",
199
- "fil_text = [word for word in word_tokens if word.lower() not in stop_words]\n",
200
- "print(word_tokens[:100])"
201
- ]
202
- },
203
- {
204
- "cell_type": "code",
205
- "execution_count": 7,
206
- "id": "ba06d703-8acf-47bc-b5cf-164e1af401c5",
207
- "metadata": {},
208
- "outputs": [
209
- {
210
- "name": "stdin",
211
- "output_type": "stream",
212
- "text": [
213
- "enter the critical value : 1\n"
214
- ]
215
- },
216
- {
217
- "name": "stdout",
218
- "output_type": "stream",
219
- "text": [
220
- "0.9900990099009901\n",
221
- "['that', 'enhance', 0.9900990099009901]\n"
222
- ]
223
- }
224
- ],
225
- "source": [
226
- "import random\n",
227
- "def collocation(w1,w2):\n",
228
- " nl=list()\n",
229
- " N=len(word_tokens)\n",
230
- " prob_w1=word_tokens.count(w1)/N\n",
231
- " prob_w2=word_tokens.count(w2)/N\n",
232
- " pop_mean=prob_w1*prob_w2\n",
233
- " count_w1w2=0\n",
234
- " for i in range(len(word_tokens)-1):\n",
235
- " if(word_tokens[i]==w1 and word_tokens[i+1]==w2):\n",
236
- " count_w1w2=count_w1w2+1\n",
237
- " sam_mean=count_w1w2/N\n",
238
- " t=(sam_mean-pop_mean)/(sam_mean/N)**0.5\n",
239
- " cv=input(\"enter the critical value : \")\n",
240
- " if(float(t) > float(cv)):\n",
241
- " print(f\"hypothesis rejected thus the given words ('{w1}', '{w2}') form a collocation\")\n",
242
- " print(t)\n",
243
- " nl.append(w1)\n",
244
- " nl.append(w2)\n",
245
- " nl.append(t)\n",
246
- " print(nl)\n",
247
- "fcol=list()\n",
248
- "i = random.randint(0,len(word_tokens))\n",
249
- "#for i in range(len(word_tokens)-1):\n",
250
- "w1=word_tokens[i]\n",
251
- "w2=word_tokens[i+1]\n",
252
- "fcol.append(collocation(w1,w2))"
253
- ]
254
- },
255
- {
256
- "cell_type": "code",
257
- "execution_count": 8,
258
- "id": "2b3fa554-68cb-445d-bd94-86c1a95b9790",
259
- "metadata": {},
260
- "outputs": [
261
- {
262
- "name": "stdin",
263
- "output_type": "stream",
264
- "text": [
265
- "enter the critical value : 2\n"
266
- ]
267
- },
268
- {
269
- "name": "stdout",
270
- "output_type": "stream",
271
- "text": [
272
- "hypothesis rejected thus the given words (',', 'and') form a collocation\n",
273
- "14.5297284132707\n"
274
- ]
275
- }
276
- ],
277
- "source": [
278
- "import random\n",
279
- "def collocation(w1,w2):\n",
280
- " nl=list()\n",
281
- " N=len(word_tokens)\n",
282
- " count_w1=word_tokens.count(w1)\n",
283
- " count_w2=word_tokens.count(w2)\n",
284
- "\n",
285
- " Exp_w1w2= ((count_w1*count_w2)/N) \n",
286
- " Exp_w1nw2= ((count_w1*(N-count_w2))/N)\n",
287
- " Exp_nw1w2= (((N-count_w1)*count_w2)/N)\n",
288
- " Exp_nw1nw2= (((N-count_w1)*(N-count_w2)/N))\n",
289
- "\n",
290
- " j=0\n",
291
- " count_w1w2=0\n",
292
- " for i in range(len(word_tokens)):\n",
293
- " if(word_tokens[i]==w1 and word_tokens[i+1]==w2):\n",
294
- " count_w1w2=count_w1w2+1\n",
295
- " count_w1w2=j\n",
296
- " \n",
297
- " Obs_w1w2=count_w1w2\n",
298
- " Obs_w1nw2=count_w1-count_w1w2\n",
299
- " Obs_nw1w2=count_w2-count_w1w2\n",
300
- " Obs_nw1nw2=N-count_w1w2\n",
301
- "\n",
302
- " X= (((Obs_w1w2-Exp_w1w2)**2)/Exp_w1w2) + (((Obs_w1nw2-Exp_w1nw2)**2)/Exp_w1nw2) + (((Obs_nw1w2-Exp_nw1w2)**2)/Exp_nw1w2) + (((Obs_nw1nw2-Exp_nw1nw2)**2)/Exp_nw1nw2)\n",
303
- " cv=int(input(\"enter the critical value : \"))\n",
304
- " if(float(X) > float(cv)):\n",
305
- " print(f\"hypothesis rejected thus the given words ('{w1}', '{w2}') form a collocation\")\n",
306
- " print(X)\n",
307
- " nl.append(w1)\n",
308
- " nl.append(w2)\n",
309
- " nl.append(X)\n",
310
- " else:print(f\"hypothesis accepted thus the given words ('{w1}', '{w2}') does not form a collocation\")\n",
311
- " return nl\n",
312
- " \n",
313
- "fcol=list()\n",
314
- "i = random.randint(0,len(word_tokens))\n",
315
- "#for i in range(len(word_tokens)-1):\n",
316
- "w1=word_tokens[i]\n",
317
- "w2=word_tokens[i+1]\n",
318
- "fcol.append(collocation(w1,w2))"
319
- ]
320
- },
321
- {
322
- "cell_type": "markdown",
323
- "id": "6df14fc7-f10c-49eb-baa5-6011c270b0b5",
324
- "metadata": {},
325
- "source": [
326
- "<hr style=\"height:10px;border-width:0;background-color:teal\">"
327
- ]
328
- },
329
- {
330
- "cell_type": "markdown",
331
- "id": "485d5490-3d7e-4476-9d3a-5055dd0127b3",
332
- "metadata": {},
333
- "source": [
334
- "<hr style=\"height:10px;border-width:0;background-color:teal\">"
335
- ]
336
- },
337
- {
338
- "cell_type": "markdown",
339
- "id": "0b961cee-e99f-4b97-a287-a92938500df5",
340
- "metadata": {},
341
- "source": [
342
- "# __3.WSD__"
343
- ]
344
- },
345
- {
346
- "cell_type": "code",
347
- "execution_count": 9,
348
- "id": "378d2a7f-b3ec-4228-b436-58e4c551adf1",
349
- "metadata": {},
350
- "outputs": [
351
- {
352
- "name": "stderr",
353
- "output_type": "stream",
354
- "text": [
355
- "[nltk_data] Downloading package stopwords to\n",
356
- "[nltk_data] C:\\Users\\sugan\\AppData\\Roaming\\nltk_data...\n",
357
- "[nltk_data] Package stopwords is already up-to-date!\n",
358
- "[nltk_data] Downloading package punkt to\n",
359
- "[nltk_data] C:\\Users\\sugan\\AppData\\Roaming\\nltk_data...\n",
360
- "[nltk_data] Package punkt is already up-to-date!\n"
361
- ]
362
- }
363
- ],
364
- "source": [
365
- "import nltk\n",
366
- "nltk.download('stopwords')\n",
367
- "nltk.download('punkt')\n",
368
- "from nltk.corpus import stopwords\n",
369
- "from nltk.tokenize import word_tokenize"
370
- ]
371
- },
372
- {
373
- "cell_type": "code",
374
- "execution_count": 10,
375
- "id": "e5418f7e-eb6c-4663-af6e-1f05e5e3ee14",
376
- "metadata": {},
377
- "outputs": [],
378
- "source": [
379
- "import pandas as pd\n",
380
- "import math"
381
- ]
382
- },
383
- {
384
- "cell_type": "code",
385
- "execution_count": 11,
386
- "id": "b902b1ab-918a-47d9-b57c-3ab140756a71",
387
- "metadata": {},
388
- "outputs": [],
389
- "source": [
390
- "f=open(\"sample2.txt\")\n",
391
- "text=f.read()\n",
392
- "data=text.splitlines()"
393
- ]
394
- },
395
- {
396
- "cell_type": "code",
397
- "execution_count": 12,
398
- "id": "7636c47c-2f57-49ff-ab65-f326ed209def",
399
- "metadata": {},
400
- "outputs": [],
401
- "source": [
402
- "ds=list()\n",
403
- "for i in data:\n",
404
- " tokens=word_tokenize(i)\n",
405
- " ds.append(tokens)"
406
- ]
407
- },
408
- {
409
- "cell_type": "code",
410
- "execution_count": 13,
411
- "id": "4ed7e570-1bb2-447b-9762-4db619615a23",
412
- "metadata": {},
413
- "outputs": [
414
- {
415
- "name": "stdout",
416
- "output_type": "stream",
417
- "text": [
418
- "['chair', 'put', 'coat', ',', 'back', 'Furniture']\n",
419
- "['chair', 'IT', 'department', 'Furniture']\n",
420
- "['where', 'here', 'put', 'chair', 'Furniture']\n",
421
- "['CSE', 'chair', 'head', 'Position']\n"
422
- ]
423
- }
424
- ],
425
- "source": [
426
- "for i in ds:\n",
427
- " print(i)"
428
- ]
429
- },
430
- {
431
- "cell_type": "code",
432
- "execution_count": 14,
433
- "id": "5b5525b9-9c64-4604-ad57-37d6674bfee9",
434
- "metadata": {},
435
- "outputs": [
436
- {
437
- "name": "stdin",
438
- "output_type": "stream",
439
- "text": [
440
- "enter sentence: coat back chair\n",
441
- "enter word to find sense: chair\n"
442
- ]
443
- },
444
- {
445
- "name": "stdout",
446
- "output_type": "stream",
447
- "text": [
448
- "-2.0 -3.0\n"
449
- ]
450
- }
451
- ],
452
- "source": [
453
- "test_sen = input(\"enter sentence:\")\n",
454
- "test_sen = test_sen.split(\" \")\n",
455
- "sense_word = input(\"enter word to find sense:\")\n",
456
- "\n",
457
- " #let us assume that there are two senses(furniture,position)\n",
458
- "cf = float(text.count(\"Furniture\"))\n",
459
- "cp = float(text.count(\"Position\"))\n",
460
- "#12 unique vocabularies\n",
461
- "scoref = math.log2((cf+1)/(cf+cp+12))\n",
462
- "scorep = math.log2((cp+1)/(cf+cp+12))\n",
463
- "print(scoref,scorep)"
464
- ]
465
- },
466
- {
467
- "cell_type": "code",
468
- "execution_count": 15,
469
- "id": "11de99e1-3654-4c51-acf3-fd1f9daeaa0b",
470
- "metadata": {},
471
- "outputs": [],
472
- "source": [
473
- "fur = list()\n",
474
- "pos = list()\n",
475
- "for i in ds:\n",
476
- " if(\"Furniture\" in i):\n",
477
- " fur.append(i)\n",
478
- " else:\n",
479
- " pos.append(i)"
480
- ]
481
- },
482
- {
483
- "cell_type": "code",
484
- "execution_count": 16,
485
- "id": "69385d62-91b3-4df5-a11d-7a60c73401e5",
486
- "metadata": {},
487
- "outputs": [
488
- {
489
- "name": "stdout",
490
- "output_type": "stream",
491
- "text": [
492
- "f: 1\n",
493
- "pf: 0.13333333333333333\n",
494
- "p: 0\n",
495
- "pp: 0.07692307692307693\n",
496
- "final scoref -4.906890595608519\n",
497
- "final scorep -6.700439718141093\n",
498
- "f: 1\n",
499
- "pf: 0.13333333333333333\n",
500
- "p: 0\n",
501
- "pp: 0.07692307692307693\n",
502
- "final scoref -4.906890595608519\n",
503
- "final scorep -6.700439718141093\n",
504
- "f: 3\n",
505
- "pf: 0.26666666666666666\n",
506
- "p: 1\n",
507
- "pp: 0.15384615384615385\n",
508
- "final scoref -3.9068905956085187\n",
509
- "final scorep -5.700439718141093\n"
510
- ]
511
- }
512
- ],
513
- "source": [
514
- "for word in test_sen:\n",
515
- " p=0\n",
516
- " f=0\n",
517
- " for i in fur:\n",
518
- " if(word in i):\n",
519
- " f=f+1\n",
520
- " for i in pos:\n",
521
- " if(word in i):\n",
522
- " p=p+1\n",
523
- " print(\"f: \",f)\n",
524
- " print(\"pf: \",(f+1)/(cf+12))\n",
525
- " print(\"p: \",p)\n",
526
- " print(\"pp: \",(p+1)/(cp+12))\n",
527
- " final_scoref= scoref + math.log2(((f+1)/(cf+12)))\n",
528
- " print(\"final scoref\",final_scoref)\n",
529
- " final_scorep= scorep + math.log2(((p+1)/(cp+12)))\n",
530
- " print(\"final scorep\",final_scorep)"
531
- ]
532
- },
533
- {
534
- "cell_type": "code",
535
- "execution_count": 17,
536
- "id": "49bba1b5-0bfb-4dc8-92a3-0560ae2f01e1",
537
- "metadata": {},
538
- "outputs": [
539
- {
540
- "name": "stdout",
541
- "output_type": "stream",
542
- "text": [
543
- "the given chair is of sense Furniture in the given sentence\n"
544
- ]
545
- }
546
- ],
547
- "source": [
548
- "if(final_scorep > final_scoref):\n",
549
- " print(\"the given \",sense_word,\"is of sense Position in the given sentence\")\n",
550
- "else:\n",
551
- " print(\"the given \",sense_word,\"is of sense Furniture in the given sentence\")"
552
- ]
553
- },
554
- {
555
- "cell_type": "markdown",
556
- "id": "fe1beacf-0473-4bfa-9669-1be8bf496013",
557
- "metadata": {},
558
- "source": [
559
- "<hr style=\"height:10px;border-width:0;background-color:teal\">"
560
- ]
561
- },
562
- {
563
- "cell_type": "markdown",
564
- "id": "f7a83d22-f60c-481c-b992-1aff240cb7dc",
565
- "metadata": {},
566
- "source": [
567
- "<hr style=\"height:10px;border-width:0;background-color:teal\">"
568
- ]
569
- },
570
- {
571
- "cell_type": "markdown",
572
- "id": "97cb94a4-daca-45d7-89fc-022550c54cb0",
573
- "metadata": {},
574
- "source": [
575
- "# __4.Hindle & Rooth__"
576
- ]
577
- },
578
- {
579
- "cell_type": "code",
580
- "execution_count": 18,
581
- "id": "fb6ea3e5-356f-49e6-add7-9ea4730f9f0a",
582
- "metadata": {},
583
- "outputs": [
584
- {
585
- "name": "stdin",
586
- "output_type": "stream",
587
- "text": [
588
- "Enter the preposition : with\n",
589
- "Enter the noun : phone\n",
590
- "Enter the Verb : wait\n"
591
- ]
592
- },
593
- {
594
- "name": "stdout",
595
- "output_type": "stream",
596
- "text": [
597
- "[('saw', 'phone')]\n",
598
- "[('went', 'meeting'), ('meeting', 'yesterday')]\n",
599
- "[('told', 'man'), ('man', 'wait')]\n",
600
- "[('gave', 'book')]\n",
601
- "[('saw', 'cat')]\n",
602
- "{'saw': 2, 'phone': 1, 'went': 1, 'meeting': 1, 'yesterday': 1, 'told': 1, 'man': 1, 'wait': 1, 'gave': 1, 'book': 1, 'cat': 1}\n",
603
- "{'phone': 1, 'yesterday': 2, 'wait': 2, 'book': 1, 'cat': 1}\n",
604
- "0\n",
605
- "1\n",
606
- "0\n",
607
- "1\n",
608
- "no attachment\n"
609
- ]
610
- }
611
- ],
612
- "source": [
613
- "import nltk\n",
614
- "import math\n",
615
- "from nltk.tokenize import word_tokenize\n",
616
- "import string\n",
617
- "from nltk.corpus import stopwords\n",
618
- "from nltk import bigrams\n",
619
- "\n",
620
- "prep = input(\"Enter the preposition : \")\n",
621
- "noun = input(\"Enter the noun : \")\n",
622
- "verb = input(\"Enter the Verb : \")\n",
623
- "\n",
624
- "stop_words = set(stopwords.words(\"english\"))\n",
625
- "\n",
626
- "sentences = [\n",
627
- " \"Saw the phone with me.\",\n",
628
- " \"Went to the meeting yesterday.\",\n",
629
- " \"Told the man to wait.\",\n",
630
- " \"Gave the book to her.\",\n",
631
- " \"Saw the cat with her.\"\n",
632
- "]\n",
633
- "\n",
634
- "unigram = {}\n",
635
- "bigram = {}\n",
636
- "\n",
637
- "for sentence in sentences:\n",
638
- " tokens = word_tokenize(sentence)\n",
639
- " tokens = [token.lower() for token in tokens if token not in string.punctuation and token not in stop_words]\n",
640
- " bigr = list(bigrams(tokens))\n",
641
- " print(bigr)\n",
642
- " for word in tokens:\n",
643
- " if word in unigram:\n",
644
- " unigram[word]+=1\n",
645
- " else:\n",
646
- " unigram[word] = 1\n",
647
- " for bi in bigr:\n",
648
- " if word in bigram:\n",
649
- " bigram[word]+=1\n",
650
- " else:\n",
651
- " bigram[word] = 1\n",
652
- "\n",
653
- "print(unigram)\n",
654
- "print(bigram)\n",
655
- "\n",
656
- "bigram.setdefault((noun.lower(),prep.lower()),0)\n",
657
- "bigram.setdefault((verb.lower(),prep.lower()),0)\n",
658
- "unigram.setdefault(noun.lower(),0)\n",
659
- "unigram.setdefault(verb.lower(),0)\n",
660
- "unigram.setdefault(prep.lower(),0)\n",
661
- "\n",
662
- "print(bigram[(noun.lower(),prep.lower())])\n",
663
- "print(unigram[noun.lower()])\n",
664
- "print(bigram[(verb.lower(),prep.lower())])\n",
665
- "print(unigram[verb.lower()])\n",
666
- "\n",
667
- "pn = bigram[(noun.lower(),prep.lower())]/unigram[noun.lower()]\n",
668
- "pv = bigram[(verb.lower(),prep.lower())]/unigram[verb.lower()]\n",
669
- "\n",
670
- "try: \n",
671
- " lam = math.log2((pv*(1-pn))/pn)\n",
672
- " if lam < 1:\n",
673
- " print(\"attached with noun\")\n",
674
- " else:\n",
675
- " print(\"attached with verb\")\n",
676
- "except ZeroDivisionError as e:\n",
677
- " print(\"no attachment\")\n",
678
- " "
679
- ]
680
- },
681
- {
682
- "cell_type": "markdown",
683
- "id": "09381c48-2e0b-4324-9535-d32bc12de7e1",
684
- "metadata": {},
685
- "source": [
686
- "<hr style=\"height:10px;border-width:0;background-color:teal\">"
687
- ]
688
- },
689
- {
690
- "cell_type": "markdown",
691
- "id": "f466a4e0-258b-4f15-9313-0a66120c788f",
692
- "metadata": {},
693
- "source": [
694
- "<hr style=\"height:10px;border-width:0;background-color:teal\">"
695
- ]
696
- },
697
- {
698
- "cell_type": "markdown",
699
- "id": "94a72f92-69f9-4b2c-82b8-6ac18f1e7268",
700
- "metadata": {},
701
- "source": [
702
- "# __5.Forward Backward Probability of Observed Sequence__"
703
- ]
704
- },
705
- {
706
- "cell_type": "code",
707
- "execution_count": 19,
708
- "id": "d0c4e603-f344-4cc6-bed7-870a28b98725",
709
- "metadata": {},
710
- "outputs": [],
711
- "source": [
712
- "states = ['cp', 'ip']\n",
713
- "ip = [1.0, 0.0]\n",
714
- "stp = [[0.7, 0.3], [0.5, 0.5]]\n",
715
- "op = ['lem', 'ice', 'cola']\n",
716
- "opp = [[0.3, 0.1, 0.6], [0.2, 0.7, 0.1]]"
717
- ]
718
- },
719
- {
720
- "cell_type": "code",
721
- "execution_count": 20,
722
- "id": "674dac88-a26e-4af4-93cf-d8467f98a872",
723
- "metadata": {},
724
- "outputs": [],
725
- "source": [
726
- "def forward_alg():\n",
727
- " alpha = []\n",
728
- " for _ in range(len(op)+1):\n",
729
- " alpha.append([0,0])\n",
730
- "\n",
731
- " '''alpha[0][0] = 1.0\n",
732
- " alpha[0][1] = 0.0\n",
733
- " #print(alpha)'''\n",
734
- " \n",
735
- " for i in range(len(alpha)):\n",
736
- " if i == 0:\n",
737
- " alpha[i][0] = ip[0]\n",
738
- " alpha[i][1] = ip[1]\n",
739
- " continue\n",
740
- " \n",
741
- " alpha[i][0] = float(float(stp[0][0]*opp[0][i-1]*alpha[i-1][0]) + float(stp[1][0]*opp[1][i-1]*alpha[i-1][1]))\n",
742
- "\n",
743
- " alpha[i][1] = float(float(stp[1][1]*opp[1][i-1]*alpha[i-1][1]) + float(stp[0][1]*opp[0][i-1]*alpha[i-1][0]))\n",
744
- "\n",
745
- " return alpha"
746
- ]
747
- },
748
- {
749
- "cell_type": "code",
750
- "execution_count": 21,
751
- "id": "da4ffe33-f516-40ae-a721-0afee9db9f31",
752
- "metadata": {},
753
- "outputs": [
754
- {
755
- "name": "stdout",
756
- "output_type": "stream",
757
- "text": [
758
- "[1.0, 0.0]\n",
759
- "[0.21, 0.09]\n",
760
- "[0.0462, 0.0378]\n",
761
- "[0.021293999999999997, 0.010206]\n",
762
- "\n",
763
- "Probability of whole sequence : 0.0315\n"
764
- ]
765
- }
766
- ],
767
- "source": [
768
- "alpha = forward_alg()\n",
769
- "pos_alpha = 0.0\n",
770
- "for i in alpha:\n",
771
- " pos_alpha = sum(i)\n",
772
- " print(i)\n",
773
- " \n",
774
- "print(\"\\nProbability of whole sequence : \",pos_alpha)"
775
- ]
776
- },
777
- {
778
- "cell_type": "code",
779
- "execution_count": 22,
780
- "id": "81593ceb-34b6-4dff-82f3-d04dd379d8a5",
781
- "metadata": {},
782
- "outputs": [],
783
- "source": [
784
- "def backward_alg():\n",
785
- " beta = []\n",
786
- " for _ in range(len(op)+1):\n",
787
- " beta.append([0.0,0.0])\n",
788
- "\n",
789
- " beta[len(op)][0] = 1.0\n",
790
- " beta[len(op)][1] = 1.0\n",
791
- " #print(beta)\n",
792
- "\n",
793
- " for i in range(len(op)-1,-1,-1):\n",
794
- " \n",
795
- " beta[i][0] = float(float(stp[0][0]*opp[0][i]*beta[i+1][0]) + float(stp[0][1]*opp[0][i]*beta[i+1][1]))\n",
796
- "\n",
797
- " beta[i][1] = float(float(stp[1][1]*opp[1][i]*beta[i+1][1]) + float(stp[1][0]*opp[1][i]*beta[i+1][0]))\n",
798
- "\n",
799
- " return beta"
800
- ]
801
- },
802
- {
803
- "cell_type": "code",
804
- "execution_count": 23,
805
- "id": "d982baed-e8e7-4abf-935c-f2f50ac3e4bc",
806
- "metadata": {},
807
- "outputs": [
808
- {
809
- "name": "stdout",
810
- "output_type": "stream",
811
- "text": [
812
- "[0.0315, 0.029]\n",
813
- "[0.045, 0.245]\n",
814
- "[0.6, 0.1]\n",
815
- "[1.0, 1.0]\n",
816
- "\n",
817
- "Probability of whole sequence : 0.0315\n"
818
- ]
819
- }
820
- ],
821
- "source": [
822
- "beta = backward_alg()\n",
823
- "for i in beta:\n",
824
- " print(i)\n",
825
- "pos_beta = beta[0][0]*ip[0] + beta[0][1]*ip[1]\n",
826
- "print(\"\\nProbability of whole sequence : \",pos_beta)"
827
- ]
828
- },
829
- {
830
- "cell_type": "markdown",
831
- "id": "b5cae044-9658-43a8-b973-1e64e83c6390",
832
- "metadata": {},
833
- "source": [
834
- "<hr style=\"height:10px;border-width:0;background-color:teal\">"
835
- ]
836
- },
837
- {
838
- "cell_type": "markdown",
839
- "id": "2041ec2e-f279-4b0c-950e-038143a802db",
840
- "metadata": {},
841
- "source": [
842
- "<hr style=\"height:10px;border-width:0;background-color:teal\">"
843
- ]
844
- },
845
- {
846
- "cell_type": "markdown",
847
- "id": "ffeabfe2-283f-47eb-98b1-250eedb203d6",
848
- "metadata": {},
849
- "source": [
850
- "# __6.Viterbi Algorithm (Best State Sequence)__"
851
- ]
852
- },
853
- {
854
- "cell_type": "code",
855
- "execution_count": 24,
856
- "id": "054ed639-31cd-489c-87d7-6f910bdff677",
857
- "metadata": {},
858
- "outputs": [],
859
- "source": [
860
- "states = ['cp', 'ip']\n",
861
- "ip = [1.0, 0.0]\n",
862
- "stp = [[0.7, 0.3], [0.5, 0.5]]\n",
863
- "op = ['lem', 'ice', 'cola']\n",
864
- "opp = [[0.3, 0.1, 0.6], [0.2, 0.7, 0.1]]"
865
- ]
866
- },
867
- {
868
- "cell_type": "code",
869
- "execution_count": 25,
870
- "id": "11e5e731-7595-450d-866e-cdd0f488d20f",
871
- "metadata": {},
872
- "outputs": [],
873
- "source": [
874
- "def viterbi_algorithm(op):\n",
875
- " delta = []\n",
876
- " psi = []\n",
877
- "\n",
878
- " # Initialize the delta and psi matrices\n",
879
- " for _ in range(len(op)):\n",
880
- " delta.append([0.0, 0.0])\n",
881
- " psi.append([0, 0])\n",
882
- "\n",
883
- " # Initialization step\n",
884
- " for i in range(len(states)):\n",
885
- " delta[0][i] = ip[i] * opp[i][0]\n",
886
- "\n",
887
- " # Recursion step\n",
888
- " for t in range(1, len(op)):\n",
889
- " for j in range(len(states)):\n",
890
- " max_prob = 0.0\n",
891
- " max_state = 0\n",
892
- "\n",
893
- " for i in range(len(states)):\n",
894
- " prob = delta[t - 1][i] * stp[i][j] * opp[j][t]\n",
895
- " if prob > max_prob:\n",
896
- " max_prob = prob\n",
897
- " max_state = i\n",
898
- "\n",
899
- " delta[t][j] = max_prob\n",
900
- " psi[t][j] = max_state\n",
901
- "\n",
902
- " # Termination step\n",
903
- " best_path_prob = max(delta[-1])\n",
904
- " best_last_state = delta[-1].index(best_path_prob)\n",
905
- "\n",
906
- " # Backtrack to find the best tag sequence\n",
907
- " best_path = [best_last_state]\n",
908
- " for t in range(len(op) - 1, 0, -1):\n",
909
- " best_last_state = psi[t][best_last_state]\n",
910
- " best_path.insert(0, best_last_state)\n",
911
- "\n",
912
- " return best_path, best_path_prob"
913
- ]
914
- },
915
- {
916
- "cell_type": "code",
917
- "execution_count": 26,
918
- "id": "9a2c4fc4-ba8e-4d4f-9f58-8f225919508b",
919
- "metadata": {},
920
- "outputs": [
921
- {
922
- "name": "stdout",
923
- "output_type": "stream",
924
- "text": [
925
- "Best Tag Sequence: ['cp', 'ip', 'cp']\n",
926
- "Probability of the Best Tag Sequence: 0.0189\n"
927
- ]
928
- }
929
- ],
930
- "source": [
931
- "# Call the Viterbi algorithm\n",
932
- "best_tag_sequence, probability = viterbi_algorithm(op)\n",
933
- "\n",
934
- "# Print the best tag sequence and its probability\n",
935
- "print(\"Best Tag Sequence:\", [states[i] for i in best_tag_sequence])\n",
936
- "print(\"Probability of the Best Tag Sequence:\", probability)"
937
- ]
938
- },
939
- {
940
- "cell_type": "markdown",
941
- "id": "aa31e1a8-6821-498d-9895-557a43205f9d",
942
- "metadata": {},
943
- "source": [
944
- "<hr style=\"height:10px;border-width:0;background-color:teal\">"
945
- ]
946
- },
947
- {
948
- "cell_type": "markdown",
949
- "id": "666040aa-05c5-4815-adf5-c64ffab0e94c",
950
- "metadata": {},
951
- "source": [
952
- "<hr style=\"height:10px;border-width:0;background-color:teal\">"
953
- ]
954
- },
955
- {
956
- "cell_type": "markdown",
957
- "id": "77249cef-b6b6-46e8-afb2-1a83730855a0",
958
- "metadata": {},
959
- "source": [
960
- "# __7.PCFG Using CYK__"
961
- ]
962
- },
963
- {
964
- "cell_type": "code",
965
- "execution_count": 27,
966
- "id": "fcbaa054-0d06-4ac6-86f6-817121de6640",
967
- "metadata": {},
968
- "outputs": [
969
- {
970
- "name": "stdout",
971
- "output_type": "stream",
972
- "text": [
973
- "Inside probability of S: 21.400000000000002\n",
974
- "Inside probability of NP: 18.479999999999997\n",
975
- "Inside probability of VP: 17.120000000000005\n",
976
- "Inside probability of Det: 0.0\n",
977
- "Inside probability of N: 0.0\n",
978
- "Inside probability of V: 0.0\n",
979
- "Total inside probability: 21.400000000000002\n"
980
- ]
981
- }
982
- ],
983
- "source": [
984
- "from collections import defaultdict\n",
985
- "from itertools import product\n",
986
- "\n",
987
- "def cyk_algorithm(words, pcfg_rules):\n",
988
- " n = len(words)\n",
989
- " table = [[defaultdict(float) for _ in range(n)] for _ in range(n)]\n",
990
- "\n",
991
- " # Initialization\n",
992
- " for i, word in enumerate(words):\n",
993
- " for nt, (prob, terminals) in pcfg_rules.items():\n",
994
- " if word in terminals:\n",
995
- " table[i][i][nt] = prob\n",
996
- "\n",
997
- " # CYK Algorithm\n",
998
- " for length in range(2, n + 1):\n",
999
- " for i in range(n - length + 1):\n",
1000
- " j = i + length - 1\n",
1001
- " for k in range(i, j):\n",
1002
- " for A, (prob_A, _) in pcfg_rules.items():\n",
1003
- " for B, (prob_B, _) in pcfg_rules.items():\n",
1004
- " for C in table[i][k]:\n",
1005
- " for D in table[k + 1][j]:\n",
1006
- " prob = prob_A * prob_B * pcfg_rules[A][1].count(C) * pcfg_rules[B][1].count(D)\n",
1007
- " table[i][j][A] += prob\n",
1008
- "\n",
1009
- " return table\n",
1010
- "\n",
1011
- "# Example PCFG rules (non-terminal -> (probability, [productions]))\n",
1012
- "pcfg_rules = {\n",
1013
- " 'S': (1.0, ['NP', 'VP']),\n",
1014
- " 'NP': (0.7, ['Det', 'N']),\n",
1015
- " 'VP': (0.8, ['V', 'NP']),\n",
1016
- " 'Det': (1.0, ['the']),\n",
1017
- " 'N': (0.6, ['cat', 'dog']),\n",
1018
- " 'V': (0.9, ['chased'])\n",
1019
- "}\n",
1020
- "\n",
1021
- "# Example input sentence\n",
1022
- "words = ['the', 'cat', 'chased', 'the', 'dog']\n",
1023
- "\n",
1024
- "# Call CYK algorithm to get inside probabilities\n",
1025
- "table = cyk_algorithm(words, pcfg_rules)\n",
1026
- "\n",
1027
- "# Inside probabilities for non-terminals in the top cell of the table\n",
1028
- "inside_probabilities = table[0][-1]\n",
1029
- "\n",
1030
- "# Print inside probabilities\n",
1031
- "for nt, prob in inside_probabilities.items():\n",
1032
- " print(f'Inside probability of {nt}: {prob}')\n",
1033
- "\n",
1034
- "# Total inside probability (probability of the whole sentence)\n",
1035
- "total_probability = inside_probabilities['S']\n",
1036
- "print(f'Total inside probability: {total_probability}')"
1037
- ]
1038
- },
1039
- {
1040
- "cell_type": "markdown",
1041
- "id": "ba442a3e-6e62-44d4-8442-d6b56eda9218",
1042
- "metadata": {},
1043
- "source": [
1044
- "<hr style=\"height:10px;border-width:0;background-color:teal\">"
1045
- ]
1046
- },
1047
- {
1048
- "cell_type": "markdown",
1049
- "id": "9c63b728",
1050
- "metadata": {},
1051
- "source": [
1052
- "<hr style=\"height:10px;border-width:0;background-color:teal\">"
1053
- ]
1054
- },
1055
- {
1056
- "cell_type": "markdown",
1057
- "id": "b467efb2",
1058
- "metadata": {},
1059
- "source": [
1060
- "# __7.PCFG Parse Tree__"
1061
- ]
1062
- },
1063
- {
1064
- "cell_type": "markdown",
1065
- "id": "0e87e154",
1066
- "metadata": {},
1067
- "source": [
1068
- "LHS `->` RHS \n",
1069
- "Element1 `|` Element2 `|` Element3 \n",
1070
- "`NP PP [0.4]` -- non-terminal symbol \n",
1071
- "`'he' [0.6]` -- terminal symbol "
1072
- ]
1073
- },
1074
- {
1075
- "cell_type": "code",
1076
- "execution_count": 28,
1077
- "id": "7fed8350",
1078
- "metadata": {},
1079
- "outputs": [],
1080
- "source": [
1081
- "grammarstring = \"\"\"\n",
1082
- "S -> NP VP [1.0]\n",
1083
- "NP -> NP PP [0.4] | 'he' [0.1] | 'dessert' [0.3] | 'lunch' [0.1] | 'saw' [0.1]\n",
1084
- "PP -> Pre NP [1.0]\n",
1085
- "VP -> Verb NP [0.3] | VP PP [0.7]\n",
1086
- "Pre -> 'with' [0.6] | 'in' [0.4]\n",
1087
- "Verb -> 'ate' [0.7] | 'saw' [0.3]\n",
1088
- "\"\"\""
1089
- ]
1090
- },
1091
- {
1092
- "cell_type": "code",
1093
- "execution_count": 29,
1094
- "id": "1623f3b9",
1095
- "metadata": {},
1096
- "outputs": [],
1097
- "source": [
1098
- "from nltk import PCFG, InsideChartParser \n",
1099
- "# Remember InsideChartParser\n",
1100
- "\n",
1101
- "grammar = PCFG.fromstring(grammarstring)\n",
1102
- "\n",
1103
- "parser = InsideChartParser(grammar=grammar)"
1104
- ]
1105
- },
1106
- {
1107
- "cell_type": "code",
1108
- "execution_count": 30,
1109
- "id": "dc73b676",
1110
- "metadata": {},
1111
- "outputs": [
1112
- {
1113
- "data": {
1114
- "text/plain": [
1115
- "['he', 'saw', 'lunch', 'with', 'dessert']"
1116
- ]
1117
- },
1118
- "execution_count": 30,
1119
- "metadata": {},
1120
- "output_type": "execute_result"
1121
- }
1122
- ],
1123
- "source": [
1124
- "from nltk.tokenize import word_tokenize\n",
1125
- "\n",
1126
- "sentence = \"he saw lunch with dessert\"\n",
1127
- "\n",
1128
- "tokens = word_tokenize(sentence)\n",
1129
- "tokens"
1130
- ]
1131
- },
1132
- {
1133
- "cell_type": "code",
1134
- "execution_count": 31,
1135
- "id": "3ad4c283",
1136
- "metadata": {},
1137
- "outputs": [
1138
- {
1139
- "name": "stdout",
1140
- "output_type": "stream",
1141
- "text": [
1142
- " S \n",
1143
- " _____________|____ \n",
1144
- " | VP \n",
1145
- " | _________|________ \n",
1146
- " | VP PP \n",
1147
- " | ____|____ ____|_____ \n",
1148
- " NP Verb NP Pre NP \n",
1149
- " | | | | | \n",
1150
- " he saw lunch with dessert\n",
1151
- "\n",
1152
- "Prob: 0.00011339999999999999\n",
1153
- " S \n",
1154
- " _________|____ \n",
1155
- " | VP \n",
1156
- " | __________|___ \n",
1157
- " | | NP \n",
1158
- " | | ________|____ \n",
1159
- " | | | PP \n",
1160
- " | | | ____|_____ \n",
1161
- " NP Verb NP Pre NP \n",
1162
- " | | | | | \n",
1163
- " he saw lunch with dessert\n",
1164
- "\n",
1165
- "Prob: 6.480000000000002e-05\n"
1166
- ]
1167
- }
1168
- ],
1169
- "source": [
1170
- "trees = parser.parse(tokens)\n",
1171
- "\n",
1172
- "for tree in trees:\n",
1173
- " tree.pretty_print() # Remember this\n",
1174
- " print(\"Prob: \", tree.prob())# .prob"
1175
- ]
1176
- },
1177
- {
1178
- "cell_type": "markdown",
1179
- "id": "03dafed0",
1180
- "metadata": {},
1181
- "source": [
1182
- "<hr style=\"height:10px;border-width:0;background-color:teal\">"
1183
- ]
1184
- },
1185
- {
1186
- "cell_type": "markdown",
1187
- "id": "6792f73a-c8d0-41b6-9e24-0d82440167cb",
1188
- "metadata": {},
1189
- "source": [
1190
- "<hr style=\"height:10px;border-width:0;background-color:teal\">"
1191
- ]
1192
- },
1193
- {
1194
- "cell_type": "markdown",
1195
- "id": "8cbd44fd-19a5-4c72-93d8-bd000f92fce9",
1196
- "metadata": {},
1197
- "source": [
1198
- "# __8.Test Classification using BOW & TF-IDF__"
1199
- ]
1200
- },
1201
- {
1202
- "cell_type": "code",
1203
- "execution_count": 32,
1204
- "id": "e288984d-5ed7-4349-bb04-c69da5dba922",
1205
- "metadata": {},
1206
- "outputs": [],
1207
- "source": [
1208
- "import warnings\n",
1209
- "warnings.filterwarnings('ignore')"
1210
- ]
1211
- },
1212
- {
1213
- "cell_type": "code",
1214
- "execution_count": 33,
1215
- "id": "0da6600d-5299-4999-ac05-0e272aa41813",
1216
- "metadata": {
1217
- "scrolled": true
1218
- },
1219
- "outputs": [
1220
- {
1221
- "name": "stdout",
1222
- "output_type": "stream",
1223
- "text": [
1224
- "Training with Bag of Words (BoW)...\n",
1225
- "Epoch 1/10\n",
1226
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m3s\u001b[0m 34ms/step - accuracy: 0.3333 - loss: 0.7565\n",
1227
- "Epoch 2/10\n",
1228
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 13ms/step - accuracy: 0.3333 - loss: 0.7452\n",
1229
- "Epoch 3/10\n",
1230
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 8ms/step - accuracy: 0.3333 - loss: 0.7609\n",
1231
- "Epoch 4/10\n",
1232
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 17ms/step - accuracy: 0.3333 - loss: 0.7832\n",
1233
- "Epoch 5/10\n",
1234
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 4ms/step - accuracy: 0.1667 - loss: 0.8181 \n",
1235
- "Epoch 6/10\n",
1236
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 8ms/step - accuracy: 0.1667 - loss: 0.8078.886\n",
1237
- "Epoch 7/10\n",
1238
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 13ms/step - accuracy: 0.3333 - loss: 0.7512\n",
1239
- "Epoch 8/10\n",
1240
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 10ms/step - accuracy: 0.3333 - loss: 0.7415\n",
1241
- "Epoch 9/10\n",
1242
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 13ms/step - accuracy: 0.3333 - loss: 0.7320\n",
1243
- "Epoch 10/10\n",
1244
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 12ms/step - accuracy: 0.3333 - loss: 0.6980\n",
1245
- "\u001b[1m1/1\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 361ms/step - accuracy: 0.0000e+00 - loss: 0.8013\n",
1246
- "BoW Model Accuracy: 0.00\n",
1247
- "Training with TF-IDF...\n",
1248
- "Epoch 1/10\n",
1249
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m3s\u001b[0m 16ms/step - accuracy: 0.3333 - loss: 0.7081\n",
1250
- "Epoch 2/10\n",
1251
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 8ms/step - accuracy: 0.1667 - loss: 0.7425 \n",
1252
- "Epoch 3/10\n",
1253
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 8ms/step - accuracy: 0.3333 - loss: 0.7165\n",
1254
- "Epoch 4/10\n",
1255
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 8ms/step - accuracy: 0.3333 - loss: 0.6989\n",
1256
- "Epoch 5/10\n",
1257
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 8ms/step - accuracy: 0.1667 - loss: 0.7169.718\n",
1258
- "Epoch 6/10\n",
1259
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 8ms/step - accuracy: 0.1667 - loss: 0.7218 \n",
1260
- "Epoch 7/10\n",
1261
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 6ms/step - accuracy: 0.1667 - loss: 0.7183.72\n",
1262
- "Epoch 8/10\n",
1263
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 17ms/step - accuracy: 0.3333 - loss: 0.6927\n",
1264
- "Epoch 9/10\n",
1265
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 0s/step - accuracy: 0.1667 - loss: 0.7046 \n",
1266
- "Epoch 10/10\n",
1267
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 17ms/step - accuracy: 0.1667 - loss: 0.7117718\n",
1268
- "\u001b[1m1/1\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 390ms/step - accuracy: 0.0000e+00 - loss: 0.8679\n",
1269
- "TF-IDF Model Accuracy: 0.00\n"
1270
- ]
1271
- }
1272
- ],
1273
- "source": [
1274
- "import numpy as np\n",
1275
- "import pandas as pd\n",
1276
- "from sklearn.model_selection import train_test_split\n",
1277
- "from sklearn.feature_extraction.text import CountVectorizer, TfidfVectorizer\n",
1278
- "from sklearn.preprocessing import LabelEncoder\n",
1279
- "import tensorflow as tf\n",
1280
- "from tensorflow.keras import Sequential\n",
1281
- "from tensorflow.keras.layers import Dense\n",
1282
- "\n",
1283
- "data = {'text': ['I love programming', 'Python is great', 'I enjoy machine learning',\n",
1284
- " 'TensorFlow is a powerful tool', 'AI is the future'],\n",
1285
- " 'label': ['positive', 'positive', 'positive', 'positive', 'neutral']}\n",
1286
- "\n",
1287
- "df = pd.DataFrame(data)\n",
1288
- "label_encoder = LabelEncoder()\n",
1289
- "df['label'] = label_encoder.fit_transform(df['label'])\n",
1290
- "X_train, X_test, y_train, y_test = train_test_split(df['text'], df['label'], test_size=0.2, random_state=42)\n",
1291
- "\n",
1292
- "# Option 1: Bag of Words (BoW)\n",
1293
- "vectorizer_bow = CountVectorizer()\n",
1294
- "X_train_bow = vectorizer_bow.fit_transform(X_train).toarray()\n",
1295
- "X_test_bow = vectorizer_bow.transform(X_test).toarray()\n",
1296
- "\n",
1297
- "# Option 2: TF-IDF\n",
1298
- "vectorizer_tfidf = TfidfVectorizer()\n",
1299
- "X_train_tfidf = vectorizer_tfidf.fit_transform(X_train).toarray()\n",
1300
- "X_test_tfidf = vectorizer_tfidf.transform(X_test).toarray()\n",
1301
- "\n",
1302
- "# Build a simple neural network with TensorFlow\n",
1303
- "def build_model(input_dim):\n",
1304
- " model = Sequential()\n",
1305
- " model.add(Dense(16, activation='relu', input_dim=input_dim))\n",
1306
- " model.add(Dense(8, activation='relu'))\n",
1307
- " model.add(Dense(1, activation='sigmoid')) # Binary classification (positive or neutral)\n",
1308
- " model.compile(optimizer='adam', loss='binary_crossentropy', metrics=['accuracy'])\n",
1309
- " return model\n",
1310
- "\n",
1311
- "\n",
1312
- "print(\"Training with Bag of Words (BoW)...\")\n",
1313
- "model_bow = build_model(X_train_bow.shape[1])\n",
1314
- "model_bow.fit(X_train_bow, y_train, epochs=10, batch_size=2, verbose=1)\n",
1315
- "\n",
1316
- "loss, accuracy = model_bow.evaluate(X_test_bow, y_test)\n",
1317
- "print(f'BoW Model Accuracy: {accuracy:.2f}')\n",
1318
- "\n",
1319
- "print(\"Training with TF-IDF...\")\n",
1320
- "model_tfidf = build_model(X_train_tfidf.shape[1])\n",
1321
- "model_tfidf.fit(X_train_tfidf, y_train, epochs=10, batch_size=2, verbose=1)\n",
1322
- "\n",
1323
- "\n",
1324
- "loss, accuracy = model_tfidf.evaluate(X_test_tfidf, y_test)\n",
1325
- "print(f'TF-IDF Model Accuracy: {accuracy:.2f}')"
1326
- ]
1327
- },
1328
- {
1329
- "cell_type": "markdown",
1330
- "id": "985e1891-59fb-426a-9fcd-afa0e2e28898",
1331
- "metadata": {},
1332
- "source": [
1333
- "<hr style=\"height:10px;border-width:0;background-color:teal\">"
1334
- ]
1335
- },
1336
- {
1337
- "cell_type": "markdown",
1338
- "id": "ee7f82a3-a9da-4139-be43-ebc5b071e342",
1339
- "metadata": {},
1340
- "source": [
1341
- "<hr style=\"height:10px;border-width:0;background-color:teal\">"
1342
- ]
1343
- },
1344
- {
1345
- "cell_type": "markdown",
1346
- "id": "6b1f3bb1-38a2-40bf-bea9-08452f33f615",
1347
- "metadata": {},
1348
- "source": [
1349
- "# __9.Word2Vec Semantic Similarity Between Words__"
1350
- ]
1351
- },
1352
- {
1353
- "cell_type": "code",
1354
- "execution_count": 34,
1355
- "id": "d2e8ca01-88e6-4574-ac39-df95af94d592",
1356
- "metadata": {},
1357
- "outputs": [
1358
- {
1359
- "name": "stdout",
1360
- "output_type": "stream",
1361
- "text": [
1362
- "Words most similar to 'programming':\n",
1363
- "the: 0.1783\n",
1364
- "i: 0.1607\n",
1365
- "a: 0.1056\n",
1366
- "great: 0.0922\n",
1367
- "python: 0.0270\n"
1368
- ]
1369
- },
1370
- {
1371
- "name": "stderr",
1372
- "output_type": "stream",
1373
- "text": [
1374
- "[nltk_data] Downloading package punkt to\n",
1375
- "[nltk_data] C:\\Users\\sugan\\AppData\\Roaming\\nltk_data...\n",
1376
- "[nltk_data] Package punkt is already up-to-date!\n"
1377
- ]
1378
- }
1379
- ],
1380
- "source": [
1381
- "#Implement word2vec model to explore the semantic similarity between the words.\n",
1382
- "import gensim\n",
1383
- "from gensim.models import Word2Vec\n",
1384
- "import nltk\n",
1385
- "nltk.download('punkt')\n",
1386
- "from nltk.tokenize import word_tokenize\n",
1387
- "sentences = ['I love programming', 'Python is great', 'I enjoy machine learning',\n",
1388
- " 'TensorFlow is a powerful tool', 'AI is the future']\n",
1389
- "\n",
1390
- "tokenized_sentences = [word_tokenize(sentence.lower()) for sentence in sentences]\n",
1391
- "\n",
1392
- "\n",
1393
- "model_w2v = Word2Vec(sentences=tokenized_sentences, vector_size=100, window=5, min_count=1, workers=4)\n",
1394
- "\n",
1395
- "# word vectors (semantic similarity)\n",
1396
- "word = 'programming'\n",
1397
- "similar_words = model_w2v.wv.most_similar(word, topn=5)\n",
1398
- "print(f\"Words most similar to '{word}':\")\n",
1399
- "for sim_word, sim_score in similar_words:\n",
1400
- " print(f\"{sim_word}: {sim_score:.4f}\")\n",
1401
- "model_w2v.save(\"word2vec_model.bin\")\n",
1402
- "#loaded_model = Word2Vec.load(\"word2vec_model.bin\")"
1403
- ]
1404
- },
1405
- {
1406
- "cell_type": "markdown",
1407
- "id": "cacb5d06-1c65-47a3-9e07-d63c718c8e58",
1408
- "metadata": {},
1409
- "source": [
1410
- "<hr style=\"height:10px;border-width:0;background-color:teal\">"
1411
- ]
1412
- },
1413
- {
1414
- "cell_type": "markdown",
1415
- "id": "50dc390b-f621-49c0-b6ee-b78153b1edfe",
1416
- "metadata": {},
1417
- "source": [
1418
- "<hr style=\"height:10px;border-width:0;background-color:teal\">"
1419
- ]
1420
- },
1421
- {
1422
- "cell_type": "markdown",
1423
- "id": "ae676c70-b4c6-4b2d-8fa0-c2e34a93130a",
1424
- "metadata": {},
1425
- "source": [
1426
- "# __10.Text Generation using LSTM__"
1427
- ]
1428
- },
1429
- {
1430
- "cell_type": "code",
1431
- "execution_count": 35,
1432
- "id": "fe84ea98-5c65-41ca-bcd0-3c24ce1ccdb9",
1433
- "metadata": {},
1434
- "outputs": [],
1435
- "source": [
1436
- "import warnings\n",
1437
- "warnings.filterwarnings('ignore')"
1438
- ]
1439
- },
1440
- {
1441
- "cell_type": "code",
1442
- "execution_count": 36,
1443
- "id": "d4f5743d-c32d-45d7-967f-374ad4c99a09",
1444
- "metadata": {
1445
- "scrolled": true
1446
- },
1447
- "outputs": [
1448
- {
1449
- "name": "stdout",
1450
- "output_type": "stream",
1451
- "text": [
1452
- "Epoch 1/100\n",
1453
- "\u001b[1m3/3\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m5s\u001b[0m 9ms/step - loss: 3.0909\n",
1454
- "Epoch 2/100\n",
1455
- "\u001b[1m3/3\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 8ms/step - loss: 3.0617 \n",
1456
- "Epoch 3/100\n",
1457
- "\u001b[1m3/3\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 8ms/step - loss: 3.0476 \n",
1458
- "Epoch 4/100\n",
1459
- "\u001b[1m3/3\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 10ms/step - loss: 3.0184\n",
1460
- "Epoch 5/100\n",
1461
- "\u001b[1m3/3\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 8ms/step - loss: 2.9871 \n",
1462
- "Epoch 6/100\n",
1463
- "\u001b[1m3/3\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 8ms/step - loss: 2.9835 \n",
1464
- "Epoch 7/100\n",
1465
- "\u001b[1m3/3\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 8ms/step - loss: 2.9310 \n",
1466
- "Epoch 8/100\n",
1467
- "\u001b[1m3/3\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 8ms/step - loss: 2.8329 \n",
1468
- "Epoch 9/100\n",
1469
- "\u001b[1m3/3\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 8ms/step - loss: 2.9373 \n",
1470
- "Epoch 10/100\n",
1471
- "\u001b[1m3/3\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 8ms/step - loss: 2.8274 \n",
1472
- "Epoch 11/100\n",
1473
- "\u001b[1m3/3\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 9ms/step - loss: 2.9145 \n",
1474
- "Epoch 12/100\n",
1475
- "\u001b[1m3/3\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 8ms/step - loss: 2.8772 \n",
1476
- "Epoch 13/100\n",
1477
- "\u001b[1m3/3\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 12ms/step - loss: 2.8658\n",
1478
- "Epoch 14/100\n",
1479
- "\u001b[1m3/3\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 8ms/step - loss: 2.8369 \n",
1480
- "Epoch 15/100\n",
1481
- "\u001b[1m3/3\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 11ms/step - loss: 2.9302\n",
1482
- "Epoch 16/100\n",
1483
- "\u001b[1m3/3\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 12ms/step - loss: 2.8489\n",
1484
- "Epoch 17/100\n",
1485
- "\u001b[1m3/3\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 11ms/step - loss: 2.7994\n",
1486
- "Epoch 18/100\n",
1487
- "\u001b[1m3/3\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 8ms/step - loss: 2.8294 \n",
1488
- "Epoch 19/100\n",
1489
- "\u001b[1m3/3\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 12ms/step - loss: 2.7825\n",
1490
- "Epoch 20/100\n",
1491
- "\u001b[1m3/3\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 12ms/step - loss: 2.7956\n",
1492
- "Epoch 21/100\n",
1493
- "\u001b[1m3/3\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 8ms/step - loss: 2.8213 \n",
1494
- "Epoch 22/100\n",
1495
- "\u001b[1m3/3\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 11ms/step - loss: 2.8103\n",
1496
- "Epoch 23/100\n",
1497
- "\u001b[1m3/3\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 8ms/step - loss: 2.7470 \n",
1498
- "Epoch 24/100\n",
1499
- "\u001b[1m3/3\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 8ms/step - loss: 2.8715 \n",
1500
- "Epoch 25/100\n",
1501
- "\u001b[1m3/3\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 8ms/step - loss: 2.7876 \n",
1502
- "Epoch 26/100\n",
1503
- "\u001b[1m3/3\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 8ms/step - loss: 2.7771 \n",
1504
- "Epoch 27/100\n",
1505
- "\u001b[1m3/3\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 5ms/step - loss: 2.8300 \n",
1506
- "Epoch 28/100\n",
1507
- "\u001b[1m3/3\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 8ms/step - loss: 2.8605 \n",
1508
- "Epoch 29/100\n",
1509
- "\u001b[1m3/3\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 8ms/step - loss: 2.8213 \n",
1510
- "Epoch 30/100\n",
1511
- "\u001b[1m3/3\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 16ms/step - loss: 2.8108 \n",
1512
- "Epoch 31/100\n",
1513
- "\u001b[1m3/3\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 10ms/step - loss: 2.8240\n",
1514
- "Epoch 32/100\n",
1515
- "\u001b[1m3/3\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 14ms/step - loss: 2.7978\n",
1516
- "Epoch 33/100\n",
1517
- "\u001b[1m3/3\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 8ms/step - loss: 2.7238 \n",
1518
- "Epoch 34/100\n",
1519
- "\u001b[1m3/3\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 12ms/step - loss: 2.8862\n",
1520
- "Epoch 35/100\n",
1521
- "\u001b[1m3/3\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 11ms/step - loss: 2.7856\n",
1522
- "Epoch 36/100\n",
1523
- "\u001b[1m3/3\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 8ms/step - loss: 2.8229 \n",
1524
- "Epoch 37/100\n",
1525
- "\u001b[1m3/3\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 8ms/step - loss: 2.7645 \n",
1526
- "Epoch 38/100\n",
1527
- "\u001b[1m3/3\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 8ms/step - loss: 2.7493 \n",
1528
- "Epoch 39/100\n",
1529
- "\u001b[1m3/3\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 9ms/step - loss: 2.7475 \n",
1530
- "Epoch 40/100\n",
1531
- "\u001b[1m3/3\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 10ms/step - loss: 2.7241\n",
1532
- "Epoch 41/100\n",
1533
- "\u001b[1m3/3\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 4ms/step - loss: 2.7854 \n",
1534
- "Epoch 42/100\n",
1535
- "\u001b[1m3/3\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 8ms/step - loss: 2.7840 \n",
1536
- "Epoch 43/100\n",
1537
- "\u001b[1m3/3\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 9ms/step - loss: 2.7436 \n",
1538
- "Epoch 44/100\n",
1539
- "\u001b[1m3/3\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 9ms/step - loss: 2.7419 \n",
1540
- "Epoch 45/100\n",
1541
- "\u001b[1m3/3\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 9ms/step - loss: 2.7192 \n",
1542
- "Epoch 46/100\n",
1543
- "\u001b[1m3/3\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 8ms/step - loss: 2.7753 \n",
1544
- "Epoch 47/100\n",
1545
- "\u001b[1m3/3\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 5ms/step - loss: 2.6806 \n",
1546
- "Epoch 48/100\n",
1547
- "\u001b[1m3/3\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 8ms/step - loss: 2.7320 \n",
1548
- "Epoch 49/100\n",
1549
- "\u001b[1m3/3\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 8ms/step - loss: 2.6792 \n",
1550
- "Epoch 50/100\n",
1551
- "\u001b[1m3/3\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 8ms/step - loss: 2.6408 \n",
1552
- "Epoch 51/100\n",
1553
- "\u001b[1m3/3\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 9ms/step - loss: 2.7425 \n",
1554
- "Epoch 52/100\n",
1555
- "\u001b[1m3/3\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 9ms/step - loss: 2.6685 \n",
1556
- "Epoch 53/100\n",
1557
- "\u001b[1m3/3\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 8ms/step - loss: 2.7425 \n",
1558
- "Epoch 54/100\n",
1559
- "\u001b[1m3/3\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 4ms/step - loss: 2.6131 \n",
1560
- "Epoch 55/100\n",
1561
- "\u001b[1m3/3\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 10ms/step - loss: 2.5712\n",
1562
- "Epoch 56/100\n",
1563
- "\u001b[1m3/3\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 5ms/step - loss: 2.5494 \n",
1564
- "Epoch 57/100\n",
1565
- "\u001b[1m3/3\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 6ms/step - loss: 2.4884 \n",
1566
- "Epoch 58/100\n",
1567
- "\u001b[1m3/3\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 4ms/step - loss: 2.5221 \n",
1568
- "Epoch 59/100\n",
1569
- "\u001b[1m3/3\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 7ms/step - loss: 2.5235 \n",
1570
- "Epoch 60/100\n",
1571
- "\u001b[1m3/3\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 7ms/step - loss: 2.5362 \n",
1572
- "Epoch 61/100\n",
1573
- "\u001b[1m3/3\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 9ms/step - loss: 2.6451 \n",
1574
- "Epoch 62/100\n",
1575
- "\u001b[1m3/3\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 9ms/step - loss: 2.5194 \n",
1576
- "Epoch 63/100\n",
1577
- "\u001b[1m3/3\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 9ms/step - loss: 2.4620 \n",
1578
- "Epoch 64/100\n",
1579
- "\u001b[1m3/3\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 8ms/step - loss: 2.5619 \n",
1580
- "Epoch 65/100\n",
1581
- "\u001b[1m3/3\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 9ms/step - loss: 2.5013 \n",
1582
- "Epoch 66/100\n",
1583
- "\u001b[1m3/3\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 7ms/step - loss: 2.4275 \n",
1584
- "Epoch 67/100\n",
1585
- "\u001b[1m3/3\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 8ms/step - loss: 2.5200 \n",
1586
- "Epoch 68/100\n",
1587
- "\u001b[1m3/3\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 8ms/step - loss: 2.3822 \n",
1588
- "Epoch 69/100\n",
1589
- "\u001b[1m3/3\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 8ms/step - loss: 2.3593 \n",
1590
- "Epoch 70/100\n",
1591
- "\u001b[1m3/3\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 8ms/step - loss: 2.3916 \n",
1592
- "Epoch 71/100\n",
1593
- "\u001b[1m3/3\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 8ms/step - loss: 2.3572 \n",
1594
- "Epoch 72/100\n",
1595
- "\u001b[1m3/3\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 8ms/step - loss: 2.3626 \n",
1596
- "Epoch 73/100\n",
1597
- "\u001b[1m3/3\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 9ms/step - loss: 2.2668 \n",
1598
- "Epoch 74/100\n",
1599
- "\u001b[1m3/3\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 8ms/step - loss: 2.2636 \n",
1600
- "Epoch 75/100\n",
1601
- "\u001b[1m3/3\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 8ms/step - loss: 2.3261 \n",
1602
- "Epoch 76/100\n",
1603
- "\u001b[1m3/3\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 12ms/step - loss: 2.3806\n",
1604
- "Epoch 77/100\n",
1605
- "\u001b[1m3/3\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 13ms/step - loss: 2.2650\n",
1606
- "Epoch 78/100\n",
1607
- "\u001b[1m3/3\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 8ms/step - loss: 2.2802 \n",
1608
- "Epoch 79/100\n",
1609
- "\u001b[1m3/3\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 8ms/step - loss: 2.1351 \n",
1610
- "Epoch 80/100\n",
1611
- "\u001b[1m3/3\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 13ms/step - loss: 2.1741\n",
1612
- "Epoch 81/100\n",
1613
- "\u001b[1m3/3\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 8ms/step - loss: 2.2270 \n",
1614
- "Epoch 82/100\n",
1615
- "\u001b[1m3/3\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 8ms/step - loss: 2.2480 \n",
1616
- "Epoch 83/100\n",
1617
- "\u001b[1m3/3\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 8ms/step - loss: 2.3334 \n",
1618
- "Epoch 84/100\n",
1619
- "\u001b[1m3/3\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 8ms/step - loss: 2.2408 \n",
1620
- "Epoch 85/100\n",
1621
- "\u001b[1m3/3\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 8ms/step - loss: 2.1549 \n",
1622
- "Epoch 86/100\n",
1623
- "\u001b[1m3/3\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 8ms/step - loss: 2.0900 \n",
1624
- "Epoch 87/100\n",
1625
- "\u001b[1m3/3\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 8ms/step - loss: 2.1039 \n",
1626
- "Epoch 88/100\n",
1627
- "\u001b[1m3/3\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 8ms/step - loss: 1.9848 \n",
1628
- "Epoch 89/100\n",
1629
- "\u001b[1m3/3\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 8ms/step - loss: 2.1165 \n",
1630
- "Epoch 90/100\n",
1631
- "\u001b[1m3/3\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 8ms/step - loss: 1.9919 \n",
1632
- "Epoch 91/100\n",
1633
- "\u001b[1m3/3\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 10ms/step - loss: 1.9953 \n",
1634
- "Epoch 92/100\n",
1635
- "\u001b[1m3/3\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 8ms/step - loss: 1.8658 \n",
1636
- "Epoch 93/100\n",
1637
- "\u001b[1m3/3\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 29ms/step - loss: 1.9966\n",
1638
- "Epoch 94/100\n",
1639
- "\u001b[1m3/3\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 8ms/step - loss: 1.9468 \n",
1640
- "Epoch 95/100\n",
1641
- "\u001b[1m3/3\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 8ms/step - loss: 1.8637 \n",
1642
- "Epoch 96/100\n",
1643
- "\u001b[1m3/3\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 7ms/step - loss: 1.9122 \n",
1644
- "Epoch 97/100\n",
1645
- "\u001b[1m3/3\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 8ms/step - loss: 1.9066 \n",
1646
- "Epoch 98/100\n",
1647
- "\u001b[1m3/3\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 8ms/step - loss: 1.8174 \n",
1648
- "Epoch 99/100\n",
1649
- "\u001b[1m3/3\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 8ms/step - loss: 1.8496 \n",
1650
- "Epoch 100/100\n",
1651
- "\u001b[1m3/3\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 8ms/step - loss: 1.8804 \n",
1652
- "This is a etmpllo nTMamppl oo tttt oeeTampl oo etampllo \n"
1653
- ]
1654
- }
1655
- ],
1656
- "source": [
1657
- "from keras.models import Sequential\n",
1658
- "from keras.layers import LSTM, Dense\n",
1659
- "import numpy as np\n",
1660
- "\n",
1661
- "# Define your text data\n",
1662
- "text = \"This is a sample text for text generation using LSTM.\"\n",
1663
- "\n",
1664
- "# Preprocess the text data\n",
1665
- "chars = sorted(list(set(text)))\n",
1666
- "char_to_int = {char: i for i, char in enumerate(chars)}\n",
1667
- "int_to_char = {i: char for i, char in enumerate(chars)}\n",
1668
- "num_chars = len(chars)\n",
1669
- "seq_length = 10\n",
1670
- "\n",
1671
- "data_X = []\n",
1672
- "data_y = []\n",
1673
- "for i in range(0, len(text) - seq_length):\n",
1674
- " seq_in = text[i:i+seq_length]\n",
1675
- " seq_out = text[i+seq_length]\n",
1676
- " data_X.append([char_to_int[char] for char in seq_in])\n",
1677
- " data_y.append(char_to_int[seq_out])\n",
1678
- "\n",
1679
- "X = np.reshape(data_X, (len(data_X), seq_length, 1))\n",
1680
- "X = X / float(num_chars)\n",
1681
- "y = np.eye(num_chars)[data_y]\n",
1682
- "\n",
1683
- "# Define and train the LSTM model\n",
1684
- "model = Sequential()\n",
1685
- "model.add(LSTM(128, input_shape=(X.shape[1], X.shape[2])))\n",
1686
- "model.add(Dense(num_chars, activation='softmax'))\n",
1687
- "model.compile(loss='categorical_crossentropy', optimizer='adam')\n",
1688
- "\n",
1689
- "model.fit(X, y, epochs=100, batch_size=16)\n",
1690
- "\n",
1691
- "# Generate text using the trained model\n",
1692
- "start_seq = \"This is a \"\n",
1693
- "generated_text = start_seq\n",
1694
- "\n",
1695
- "for _ in range(50):\n",
1696
- " x = np.reshape([char_to_int[char] for char in start_seq], (1, len(start_seq), 1))\n",
1697
- " x = x / float(num_chars)\n",
1698
- " prediction = model.predict(x, verbose=0)\n",
1699
- " index = np.argmax(prediction)\n",
1700
- " result = int_to_char[index]\n",
1701
- " generated_text += result\n",
1702
- " start_seq = start_seq[1:] + result\n",
1703
- "\n",
1704
- "print(generated_text)"
1705
- ]
1706
- },
1707
- {
1708
- "cell_type": "markdown",
1709
- "id": "e2c2b34d-753c-46fe-af3b-0c30fea31eb9",
1710
- "metadata": {},
1711
- "source": [
1712
- "<hr style=\"height:10px;border-width:0;background-color:teal\">"
1713
- ]
1714
- },
1715
- {
1716
- "cell_type": "markdown",
1717
- "id": "d0bbbbcf",
1718
- "metadata": {},
1719
- "source": [
1720
- "<hr style=\"height:10px;border-width:0;background-color:teal\">"
1721
- ]
1722
- },
1723
- {
1724
- "cell_type": "markdown",
1725
- "id": "628a157b",
1726
- "metadata": {},
1727
- "source": [
1728
- "# __11.Machine Translation System__"
1729
- ]
1730
- },
1731
- {
1732
- "cell_type": "code",
1733
- "execution_count": 37,
1734
- "id": "8f975075",
1735
- "metadata": {},
1736
- "outputs": [],
1737
- "source": [
1738
- "import warnings\n",
1739
- "warnings.filterwarnings('ignore')"
1740
- ]
1741
- },
1742
- {
1743
- "cell_type": "code",
1744
- "execution_count": 38,
1745
- "id": "1109aec3",
1746
- "metadata": {
1747
- "_cell_guid": "b1076dfc-b9ad-4769-8c92-a6c4dae69d19",
1748
- "_uuid": "8f2839f25d086af736a60e9eeb907d3b93b6e0e5"
1749
- },
1750
- "outputs": [],
1751
- "source": [
1752
- "import tensorflow as tf\n",
1753
- "import numpy as np\n",
1754
- "import pandas as pd"
1755
- ]
1756
- },
1757
- {
1758
- "cell_type": "code",
1759
- "execution_count": 39,
1760
- "id": "193e3bff",
1761
- "metadata": {},
1762
- "outputs": [
1763
- {
1764
- "data": {
1765
- "text/html": [
1766
- "<div>\n",
1767
- "<style scoped>\n",
1768
- " .dataframe tbody tr th:only-of-type {\n",
1769
- " vertical-align: middle;\n",
1770
- " }\n",
1771
- "\n",
1772
- " .dataframe tbody tr th {\n",
1773
- " vertical-align: top;\n",
1774
- " }\n",
1775
- "\n",
1776
- " .dataframe thead th {\n",
1777
- " text-align: right;\n",
1778
- " }\n",
1779
- "</style>\n",
1780
- "<table border=\"1\" class=\"dataframe\">\n",
1781
- " <thead>\n",
1782
- " <tr style=\"text-align: right;\">\n",
1783
- " <th></th>\n",
1784
- " <th>english</th>\n",
1785
- " <th>spanish</th>\n",
1786
- " </tr>\n",
1787
- " </thead>\n",
1788
- " <tbody>\n",
1789
- " <tr>\n",
1790
- " <th>0</th>\n",
1791
- " <td>Go.</td>\n",
1792
- " <td>Ve.</td>\n",
1793
- " </tr>\n",
1794
- " <tr>\n",
1795
- " <th>1</th>\n",
1796
- " <td>Go.</td>\n",
1797
- " <td>Vete.</td>\n",
1798
- " </tr>\n",
1799
- " <tr>\n",
1800
- " <th>2</th>\n",
1801
- " <td>Go.</td>\n",
1802
- " <td>Vaya.</td>\n",
1803
- " </tr>\n",
1804
- " <tr>\n",
1805
- " <th>3</th>\n",
1806
- " <td>Go.</td>\n",
1807
- " <td>Váyase.</td>\n",
1808
- " </tr>\n",
1809
- " <tr>\n",
1810
- " <th>4</th>\n",
1811
- " <td>Hi.</td>\n",
1812
- " <td>Hola.</td>\n",
1813
- " </tr>\n",
1814
- " <tr>\n",
1815
- " <th>5</th>\n",
1816
- " <td>Run!</td>\n",
1817
- " <td>¡Corre!</td>\n",
1818
- " </tr>\n",
1819
- " <tr>\n",
1820
- " <th>6</th>\n",
1821
- " <td>Run.</td>\n",
1822
- " <td>Corred.</td>\n",
1823
- " </tr>\n",
1824
- " <tr>\n",
1825
- " <th>7</th>\n",
1826
- " <td>Who?</td>\n",
1827
- " <td>¿Quién?</td>\n",
1828
- " </tr>\n",
1829
- " <tr>\n",
1830
- " <th>8</th>\n",
1831
- " <td>Fire!</td>\n",
1832
- " <td>¡Fuego!</td>\n",
1833
- " </tr>\n",
1834
- " <tr>\n",
1835
- " <th>9</th>\n",
1836
- " <td>Fire!</td>\n",
1837
- " <td>¡Incendio!</td>\n",
1838
- " </tr>\n",
1839
- " </tbody>\n",
1840
- "</table>\n",
1841
- "</div>"
1842
- ],
1843
- "text/plain": [
1844
- " english spanish\n",
1845
- "0 Go. Ve.\n",
1846
- "1 Go. Vete.\n",
1847
- "2 Go. Vaya.\n",
1848
- "3 Go. Váyase.\n",
1849
- "4 Hi. Hola.\n",
1850
- "5 Run! ¡Corre!\n",
1851
- "6 Run. Corred.\n",
1852
- "7 Who? ¿Quién?\n",
1853
- "8 Fire! ¡Fuego!\n",
1854
- "9 Fire! ¡Incendio!"
1855
- ]
1856
- },
1857
- "execution_count": 39,
1858
- "metadata": {},
1859
- "output_type": "execute_result"
1860
- }
1861
- ],
1862
- "source": [
1863
- "df = pd.read_csv('data.csv')\n",
1864
- "df.head(10)"
1865
- ]
1866
- },
1867
- {
1868
- "cell_type": "code",
1869
- "execution_count": 40,
1870
- "id": "21e22ed8",
1871
- "metadata": {},
1872
- "outputs": [
1873
- {
1874
- "data": {
1875
- "text/plain": [
1876
- "Index(['english', 'spanish'], dtype='object')"
1877
- ]
1878
- },
1879
- "execution_count": 40,
1880
- "metadata": {},
1881
- "output_type": "execute_result"
1882
- }
1883
- ],
1884
- "source": [
1885
- "df.columns"
1886
- ]
1887
- },
1888
- {
1889
- "cell_type": "code",
1890
- "execution_count": 41,
1891
- "id": "45254233",
1892
- "metadata": {},
1893
- "outputs": [],
1894
- "source": [
1895
- "source_vocab = set(' '.join(df['english'][25:125]))\n",
1896
- "target_vocab = set(' '.join(df['spanish'][25:125]))\n",
1897
- "source_vocab_size = len(source_vocab)\n",
1898
- "target_vocab_size = len(target_vocab)"
1899
- ]
1900
- },
1901
- {
1902
- "cell_type": "code",
1903
- "execution_count": 42,
1904
- "id": "a1d93d7c",
1905
- "metadata": {},
1906
- "outputs": [
1907
- {
1908
- "name": "stdout",
1909
- "output_type": "stream",
1910
- "text": [
1911
- "{'r', 'C', '1', 'g', 'c', 'D', 'W', 'p', \"'\", 'R', 'y', '!', 'o', 'n', 'H', 'u', 'O', 'I', 'e', '.', 'm', 'B', 't', 'N', 'i', 'L', 'A', 's', '9', 'T', 'a', 'k', 'w', 'S', 'l', 'd', 'x', 'G', 'f', 'b', '?', 'h', 'q', ' '}\n",
1912
- "{'r', 'C', '¡', ',', 'g', 'c', 'D', 'Y', 'p', '¿', 'R', '!', 'y', 'o', 'n', 'H', 'í', 'u', 'é', 'O', 'É', 'E', 'I', 'á', 'e', '.', 'm', 'B', 't', 'N', 'i', 'Á', 'L', 'ú', 'A', 's', 'V', 'T', 'a', 'M', 'j', 'P', 'S', 'd', 'l', 'z', 'ó', 'G', 'Ó', 'f', 'b', '?', 'h', 'v', 'q', 'U', ' '}\n"
1913
- ]
1914
- }
1915
- ],
1916
- "source": [
1917
- "print(source_vocab)\n",
1918
- "print(target_vocab)"
1919
- ]
1920
- },
1921
- {
1922
- "cell_type": "code",
1923
- "execution_count": 43,
1924
- "id": "658cc282",
1925
- "metadata": {},
1926
- "outputs": [],
1927
- "source": [
1928
- "source_char_to_int = {char: idx for idx, char in enumerate(source_vocab)}\n",
1929
- "target_char_to_int = {char: idx for idx, char in enumerate(target_vocab)}\n",
1930
- "source_int_to_char = {idx: char for char, idx in source_char_to_int.items()}\n",
1931
- "target_int_to_char = {idx: char for char, idx in target_char_to_int.items()}"
1932
- ]
1933
- },
1934
- {
1935
- "cell_type": "code",
1936
- "execution_count": 44,
1937
- "id": "fdee83fe",
1938
- "metadata": {},
1939
- "outputs": [],
1940
- "source": [
1941
- "# Convert text sequences to integer sequences\n",
1942
- "source_sequences = [[source_char_to_int[char] for char in text] for text in df['english'][25:125]]\n",
1943
- "target_sequences = [[target_char_to_int[char] for char in text] for text in df['spanish'][25:125]]"
1944
- ]
1945
- },
1946
- {
1947
- "cell_type": "code",
1948
- "execution_count": 45,
1949
- "id": "5ad12206",
1950
- "metadata": {},
1951
- "outputs": [],
1952
- "source": [
1953
- "# Pad sequences to the same length\n",
1954
- "max_sequence_length = max(len(seq) for seq in source_sequences)\n",
1955
- "source_sequences = tf.keras.preprocessing.sequence.pad_sequences(source_sequences, maxlen=max_sequence_length, padding='post')\n",
1956
- "target_sequences = tf.keras.preprocessing.sequence.pad_sequences(target_sequences, maxlen=max_sequence_length, padding='post')"
1957
- ]
1958
- },
1959
- {
1960
- "cell_type": "code",
1961
- "execution_count": 46,
1962
- "id": "0bb2d362",
1963
- "metadata": {},
1964
- "outputs": [],
1965
- "source": [
1966
- "# Build the model\n",
1967
- "input_shape = (max_sequence_length, source_vocab_size)\n",
1968
- "output_shape = (max_sequence_length, target_vocab_size)\n",
1969
- "\n",
1970
- "model = tf.keras.models.Sequential([\n",
1971
- " # Embedding layer with a larger dimension for richer word representations\n",
1972
- " tf.keras.layers.Embedding(source_vocab_size, 512, input_length=max_sequence_length),\n",
1973
- "\n",
1974
- " # First Bidirectional RNN layer with dropout and L2 regularization\n",
1975
- " tf.keras.layers.Bidirectional(tf.keras.layers.SimpleRNN(512, return_sequences=True, \n",
1976
- " kernel_regularizer=tf.keras.regularizers.l2(0.001))),\n",
1977
- " tf.keras.layers.Dropout(0.4),\n",
1978
- "\n",
1979
- " # Second RNN layer with higher units and dropout\n",
1980
- " tf.keras.layers.SimpleRNN(512, return_sequences=True),\n",
1981
- " tf.keras.layers.Dropout(0.4),\n",
1982
- "\n",
1983
- " # Third RNN layer for more complex patterns\n",
1984
- " tf.keras.layers.SimpleRNN(256, return_sequences=True),\n",
1985
- " tf.keras.layers.Dropout(0.3),\n",
1986
- "\n",
1987
- " # Dense layer for more feature learning\n",
1988
- " tf.keras.layers.Dense(512, activation='relu'),\n",
1989
- "\n",
1990
- " # Output layer to map to the target vocabulary\n",
1991
- " tf.keras.layers.Dense(target_vocab_size, activation='softmax')\n",
1992
- "])\n",
1993
- "\n",
1994
- "model.compile(optimizer='adam', loss='categorical_crossentropy', metrics=['accuracy'])"
1995
- ]
1996
- },
1997
- {
1998
- "cell_type": "code",
1999
- "execution_count": 47,
2000
- "id": "1973254b",
2001
- "metadata": {},
2002
- "outputs": [],
2003
- "source": [
2004
- "# One-hot encode the target sequences\n",
2005
- "target_sequences_one_hot = np.array([tf.keras.utils.to_categorical(seq, num_classes=target_vocab_size) for seq in target_sequences])"
2006
- ]
2007
- },
2008
- {
2009
- "cell_type": "code",
2010
- "execution_count": 48,
2011
- "id": "cba9a632",
2012
- "metadata": {
2013
- "scrolled": true
2014
- },
2015
- "outputs": [
2016
- {
2017
- "name": "stdout",
2018
- "output_type": "stream",
2019
- "text": [
2020
- "Epoch 1/250\n",
2021
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m18s\u001b[0m 98ms/step - accuracy: 0.0332 - loss: 5.0551\n",
2022
- "Epoch 2/250\n",
2023
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 92ms/step - accuracy: 0.1902 - loss: 4.3524\n",
2024
- "Epoch 3/250\n",
2025
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 81ms/step - accuracy: 0.1941 - loss: 4.0500\n",
2026
- "Epoch 4/250\n",
2027
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 96ms/step - accuracy: 0.2376 - loss: 3.7719\n",
2028
- "Epoch 5/250\n",
2029
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 86ms/step - accuracy: 0.3000 - loss: 3.5977\n",
2030
- "Epoch 6/250\n",
2031
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 82ms/step - accuracy: 0.2775 - loss: 3.4530\n",
2032
- "Epoch 7/250\n",
2033
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 84ms/step - accuracy: 0.3259 - loss: 3.2802\n",
2034
- "Epoch 8/250\n",
2035
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 82ms/step - accuracy: 0.3594 - loss: 3.1655\n",
2036
- "Epoch 9/250\n",
2037
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 98ms/step - accuracy: 0.3916 - loss: 2.9952\n",
2038
- "Epoch 10/250\n",
2039
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 81ms/step - accuracy: 0.4072 - loss: 2.9167\n",
2040
- "Epoch 11/250\n",
2041
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 90ms/step - accuracy: 0.4588 - loss: 2.7537\n",
2042
- "Epoch 12/250\n",
2043
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 81ms/step - accuracy: 0.4680 - loss: 2.6349\n",
2044
- "Epoch 13/250\n",
2045
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 95ms/step - accuracy: 0.5005 - loss: 2.5371\n",
2046
- "Epoch 14/250\n",
2047
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 77ms/step - accuracy: 0.5058 - loss: 2.4396\n",
2048
- "Epoch 15/250\n",
2049
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 92ms/step - accuracy: 0.5176 - loss: 2.3706\n",
2050
- "Epoch 16/250\n",
2051
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 80ms/step - accuracy: 0.5162 - loss: 2.3273\n",
2052
- "Epoch 17/250\n",
2053
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 89ms/step - accuracy: 0.5503 - loss: 2.1850\n",
2054
- "Epoch 18/250\n",
2055
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 91ms/step - accuracy: 0.5601 - loss: 2.1380\n",
2056
- "Epoch 19/250\n",
2057
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 90ms/step - accuracy: 0.5955 - loss: 2.0653\n",
2058
- "Epoch 20/250\n",
2059
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 91ms/step - accuracy: 0.5852 - loss: 2.0299\n",
2060
- "Epoch 21/250\n",
2061
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 83ms/step - accuracy: 0.5741 - loss: 1.9942\n",
2062
- "Epoch 22/250\n",
2063
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 82ms/step - accuracy: 0.6189 - loss: 1.8572\n",
2064
- "Epoch 23/250\n",
2065
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 96ms/step - accuracy: 0.6310 - loss: 1.8258\n",
2066
- "Epoch 24/250\n",
2067
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 89ms/step - accuracy: 0.6203 - loss: 1.7997\n",
2068
- "Epoch 25/250\n",
2069
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 97ms/step - accuracy: 0.6476 - loss: 1.7557\n",
2070
- "Epoch 26/250\n",
2071
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 88ms/step - accuracy: 0.6358 - loss: 1.6978\n",
2072
- "Epoch 27/250\n",
2073
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 82ms/step - accuracy: 0.6422 - loss: 1.6589\n",
2074
- "Epoch 28/250\n",
2075
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 108ms/step - accuracy: 0.6605 - loss: 1.6016\n",
2076
- "Epoch 29/250\n",
2077
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 80ms/step - accuracy: 0.6668 - loss: 1.5838\n",
2078
- "Epoch 30/250\n",
2079
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 86ms/step - accuracy: 0.6751 - loss: 1.5420\n",
2080
- "Epoch 31/250\n",
2081
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 85ms/step - accuracy: 0.6892 - loss: 1.4734\n",
2082
- "Epoch 32/250\n",
2083
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 87ms/step - accuracy: 0.6651 - loss: 1.5056\n",
2084
- "Epoch 33/250\n",
2085
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 90ms/step - accuracy: 0.6720 - loss: 1.5164\n",
2086
- "Epoch 34/250\n",
2087
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 124ms/step - accuracy: 0.6524 - loss: 1.5097\n",
2088
- "Epoch 35/250\n",
2089
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 101ms/step - accuracy: 0.7001 - loss: 1.4014\n",
2090
- "Epoch 36/250\n",
2091
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 88ms/step - accuracy: 0.6817 - loss: 1.4253\n",
2092
- "Epoch 37/250\n",
2093
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 87ms/step - accuracy: 0.6706 - loss: 1.3971\n",
2094
- "Epoch 38/250\n",
2095
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 87ms/step - accuracy: 0.6737 - loss: 1.3812\n",
2096
- "Epoch 39/250\n",
2097
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 105ms/step - accuracy: 0.6513 - loss: 1.4100\n",
2098
- "Epoch 40/250\n",
2099
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 105ms/step - accuracy: 0.7072 - loss: 1.3206\n",
2100
- "Epoch 41/250\n",
2101
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 90ms/step - accuracy: 0.7014 - loss: 1.2956\n",
2102
- "Epoch 42/250\n",
2103
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 97ms/step - accuracy: 0.6846 - loss: 1.2950\n",
2104
- "Epoch 43/250\n",
2105
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 111ms/step - accuracy: 0.6892 - loss: 1.2917\n",
2106
- "Epoch 44/250\n",
2107
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 100ms/step - accuracy: 0.6980 - loss: 1.2683\n",
2108
- "Epoch 45/250\n",
2109
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 101ms/step - accuracy: 0.6925 - loss: 1.2881\n",
2110
- "Epoch 46/250\n",
2111
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 96ms/step - accuracy: 0.7074 - loss: 1.2025\n",
2112
- "Epoch 47/250\n",
2113
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 97ms/step - accuracy: 0.7072 - loss: 1.2442\n",
2114
- "Epoch 48/250\n",
2115
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 102ms/step - accuracy: 0.6908 - loss: 1.2082\n",
2116
- "Epoch 49/250\n",
2117
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 102ms/step - accuracy: 0.6817 - loss: 1.2191\n",
2118
- "Epoch 50/250\n",
2119
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 98ms/step - accuracy: 0.7042 - loss: 1.1976\n",
2120
- "Epoch 51/250\n",
2121
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 95ms/step - accuracy: 0.6920 - loss: 1.1916\n",
2122
- "Epoch 52/250\n",
2123
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 102ms/step - accuracy: 0.7014 - loss: 1.1434\n",
2124
- "Epoch 53/250\n",
2125
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 102ms/step - accuracy: 0.6987 - loss: 1.1585\n",
2126
- "Epoch 54/250\n",
2127
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 81ms/step - accuracy: 0.7030 - loss: 1.1344\n",
2128
- "Epoch 55/250\n",
2129
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 82ms/step - accuracy: 0.6830 - loss: 1.1507\n",
2130
- "Epoch 56/250\n",
2131
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 82ms/step - accuracy: 0.6954 - loss: 1.1113\n",
2132
- "Epoch 57/250\n",
2133
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 91ms/step - accuracy: 0.7101 - loss: 1.0874\n",
2134
- "Epoch 58/250\n",
2135
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 83ms/step - accuracy: 0.7162 - loss: 1.0849\n",
2136
- "Epoch 59/250\n",
2137
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 81ms/step - accuracy: 0.7182 - loss: 1.0639\n",
2138
- "Epoch 60/250\n",
2139
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 75ms/step - accuracy: 0.6918 - loss: 1.0981\n",
2140
- "Epoch 61/250\n",
2141
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 81ms/step - accuracy: 0.7063 - loss: 1.0996\n",
2142
- "Epoch 62/250\n",
2143
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 92ms/step - accuracy: 0.7042 - loss: 1.1236\n",
2144
- "Epoch 63/250\n",
2145
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 77ms/step - accuracy: 0.7015 - loss: 1.0795\n",
2146
- "Epoch 64/250\n",
2147
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 90ms/step - accuracy: 0.7023 - loss: 1.0363\n",
2148
- "Epoch 65/250\n",
2149
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 88ms/step - accuracy: 0.6922 - loss: 1.0601\n",
2150
- "Epoch 66/250\n",
2151
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 101ms/step - accuracy: 0.6931 - loss: 1.0601\n",
2152
- "Epoch 67/250\n",
2153
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 90ms/step - accuracy: 0.6897 - loss: 1.0596\n",
2154
- "Epoch 68/250\n",
2155
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 90ms/step - accuracy: 0.6944 - loss: 1.0643\n",
2156
- "Epoch 69/250\n",
2157
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 83ms/step - accuracy: 0.6896 - loss: 1.0459\n",
2158
- "Epoch 70/250\n",
2159
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 82ms/step - accuracy: 0.6990 - loss: 1.0237\n",
2160
- "Epoch 71/250\n",
2161
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 89ms/step - accuracy: 0.7130 - loss: 0.9944\n",
2162
- "Epoch 72/250\n",
2163
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 78ms/step - accuracy: 0.7300 - loss: 0.9652\n",
2164
- "Epoch 73/250\n",
2165
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 103ms/step - accuracy: 0.6916 - loss: 1.0241\n",
2166
- "Epoch 74/250\n",
2167
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 105ms/step - accuracy: 0.7275 - loss: 0.9508\n",
2168
- "Epoch 75/250\n",
2169
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 81ms/step - accuracy: 0.6975 - loss: 1.0039\n",
2170
- "Epoch 76/250\n",
2171
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 93ms/step - accuracy: 0.7142 - loss: 0.9610\n",
2172
- "Epoch 77/250\n",
2173
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 94ms/step - accuracy: 0.7171 - loss: 0.9440\n",
2174
- "Epoch 78/250\n",
2175
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 79ms/step - accuracy: 0.7109 - loss: 0.9677\n",
2176
- "Epoch 79/250\n",
2177
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 89ms/step - accuracy: 0.6848 - loss: 0.9847\n",
2178
- "Epoch 80/250\n",
2179
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 82ms/step - accuracy: 0.6812 - loss: 0.9893\n",
2180
- "Epoch 81/250\n",
2181
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 84ms/step - accuracy: 0.7080 - loss: 0.9469\n",
2182
- "Epoch 82/250\n",
2183
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 99ms/step - accuracy: 0.7026 - loss: 0.9758\n",
2184
- "Epoch 83/250\n",
2185
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 85ms/step - accuracy: 0.7215 - loss: 0.9237\n",
2186
- "Epoch 84/250\n",
2187
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 81ms/step - accuracy: 0.7120 - loss: 0.9096\n",
2188
- "Epoch 85/250\n",
2189
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 82ms/step - accuracy: 0.7119 - loss: 0.9188\n",
2190
- "Epoch 86/250\n",
2191
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 87ms/step - accuracy: 0.7285 - loss: 0.8869\n",
2192
- "Epoch 87/250\n",
2193
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 104ms/step - accuracy: 0.7050 - loss: 0.9303\n",
2194
- "Epoch 88/250\n",
2195
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 90ms/step - accuracy: 0.7056 - loss: 0.9102\n",
2196
- "Epoch 89/250\n",
2197
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 88ms/step - accuracy: 0.7198 - loss: 0.8687\n",
2198
- "Epoch 90/250\n",
2199
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 83ms/step - accuracy: 0.7058 - loss: 0.9212\n",
2200
- "Epoch 91/250\n",
2201
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 113ms/step - accuracy: 0.7241 - loss: 0.8748\n",
2202
- "Epoch 92/250\n",
2203
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 98ms/step - accuracy: 0.7231 - loss: 0.8816\n",
2204
- "Epoch 93/250\n",
2205
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 83ms/step - accuracy: 0.7021 - loss: 0.8926\n",
2206
- "Epoch 94/250\n",
2207
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 83ms/step - accuracy: 0.7030 - loss: 0.8792\n",
2208
- "Epoch 95/250\n",
2209
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 89ms/step - accuracy: 0.7187 - loss: 0.8641\n",
2210
- "Epoch 96/250\n",
2211
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 94ms/step - accuracy: 0.7029 - loss: 0.8970\n",
2212
- "Epoch 97/250\n",
2213
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 97ms/step - accuracy: 0.7188 - loss: 0.8607\n",
2214
- "Epoch 98/250\n",
2215
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 110ms/step - accuracy: 0.7189 - loss: 0.8455\n",
2216
- "Epoch 99/250\n",
2217
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 85ms/step - accuracy: 0.6762 - loss: 0.9206\n",
2218
- "Epoch 100/250\n",
2219
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 85ms/step - accuracy: 0.7325 - loss: 0.8306\n",
2220
- "Epoch 101/250\n",
2221
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 87ms/step - accuracy: 0.7273 - loss: 0.8547\n",
2222
- "Epoch 102/250\n",
2223
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 87ms/step - accuracy: 0.7066 - loss: 0.8609\n",
2224
- "Epoch 103/250\n",
2225
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 123ms/step - accuracy: 0.7102 - loss: 0.8325\n",
2226
- "Epoch 104/250\n",
2227
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 102ms/step - accuracy: 0.7021 - loss: 0.8702\n",
2228
- "Epoch 105/250\n",
2229
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 90ms/step - accuracy: 0.6900 - loss: 0.8428\n",
2230
- "Epoch 106/250\n",
2231
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 89ms/step - accuracy: 0.7191 - loss: 0.8082\n",
2232
- "Epoch 107/250\n",
2233
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 74ms/step - accuracy: 0.7003 - loss: 0.8455\n",
2234
- "Epoch 108/250\n",
2235
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 93ms/step - accuracy: 0.7091 - loss: 0.8459\n",
2236
- "Epoch 109/250\n",
2237
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 93ms/step - accuracy: 0.6809 - loss: 0.8729\n",
2238
- "Epoch 110/250\n",
2239
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 82ms/step - accuracy: 0.7125 - loss: 0.7892\n",
2240
- "Epoch 111/250\n",
2241
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 91ms/step - accuracy: 0.6795 - loss: 0.8472\n",
2242
- "Epoch 112/250\n",
2243
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 97ms/step - accuracy: 0.7037 - loss: 0.8527\n",
2244
- "Epoch 113/250\n",
2245
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 78ms/step - accuracy: 0.6933 - loss: 0.8671\n",
2246
- "Epoch 114/250\n",
2247
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 82ms/step - accuracy: 0.7370 - loss: 0.7724\n",
2248
- "Epoch 115/250\n",
2249
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 85ms/step - accuracy: 0.7219 - loss: 0.7740\n",
2250
- "Epoch 116/250\n",
2251
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 97ms/step - accuracy: 0.7058 - loss: 0.8154\n",
2252
- "Epoch 117/250\n",
2253
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 89ms/step - accuracy: 0.7126 - loss: 0.8193\n",
2254
- "Epoch 118/250\n",
2255
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 91ms/step - accuracy: 0.7002 - loss: 0.8151\n",
2256
- "Epoch 119/250\n",
2257
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 87ms/step - accuracy: 0.7084 - loss: 0.7834\n",
2258
- "Epoch 120/250\n",
2259
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 99ms/step - accuracy: 0.7088 - loss: 0.7862\n",
2260
- "Epoch 121/250\n",
2261
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 96ms/step - accuracy: 0.6862 - loss: 0.8205\n",
2262
- "Epoch 122/250\n",
2263
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 89ms/step - accuracy: 0.7049 - loss: 0.8081\n",
2264
- "Epoch 123/250\n",
2265
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 85ms/step - accuracy: 0.7143 - loss: 0.7705\n",
2266
- "Epoch 124/250\n",
2267
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 80ms/step - accuracy: 0.7136 - loss: 0.7716\n",
2268
- "Epoch 125/250\n",
2269
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 79ms/step - accuracy: 0.7113 - loss: 0.7876\n",
2270
- "Epoch 126/250\n",
2271
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 73ms/step - accuracy: 0.6986 - loss: 0.7537\n",
2272
- "Epoch 127/250\n",
2273
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 137ms/step - accuracy: 0.7258 - loss: 0.7602\n",
2274
- "Epoch 128/250\n",
2275
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 89ms/step - accuracy: 0.6995 - loss: 0.7848\n",
2276
- "Epoch 129/250\n",
2277
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 100ms/step - accuracy: 0.7095 - loss: 0.8014\n",
2278
- "Epoch 130/250\n",
2279
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 80ms/step - accuracy: 0.7409 - loss: 0.7388\n",
2280
- "Epoch 131/250\n",
2281
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 84ms/step - accuracy: 0.7035 - loss: 0.7941\n",
2282
- "Epoch 132/250\n",
2283
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 100ms/step - accuracy: 0.7225 - loss: 0.7515\n",
2284
- "Epoch 133/250\n",
2285
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 81ms/step - accuracy: 0.7037 - loss: 0.7950\n",
2286
- "Epoch 134/250\n",
2287
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 86ms/step - accuracy: 0.7077 - loss: 0.7918\n",
2288
- "Epoch 135/250\n",
2289
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 77ms/step - accuracy: 0.7032 - loss: 0.8031\n",
2290
- "Epoch 136/250\n",
2291
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 81ms/step - accuracy: 0.7058 - loss: 0.7903\n",
2292
- "Epoch 137/250\n",
2293
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 74ms/step - accuracy: 0.7001 - loss: 0.7900\n",
2294
- "Epoch 138/250\n",
2295
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 90ms/step - accuracy: 0.7118 - loss: 0.7422\n",
2296
- "Epoch 139/250\n",
2297
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 98ms/step - accuracy: 0.7091 - loss: 0.7627\n",
2298
- "Epoch 140/250\n",
2299
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 84ms/step - accuracy: 0.7164 - loss: 0.7400\n",
2300
- "Epoch 141/250\n",
2301
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 83ms/step - accuracy: 0.6960 - loss: 0.7712\n",
2302
- "Epoch 142/250\n",
2303
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 96ms/step - accuracy: 0.7146 - loss: 0.7727\n",
2304
- "Epoch 143/250\n",
2305
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 97ms/step - accuracy: 0.7089 - loss: 0.7782\n",
2306
- "Epoch 144/250\n",
2307
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 87ms/step - accuracy: 0.7268 - loss: 0.7083\n",
2308
- "Epoch 145/250\n",
2309
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 95ms/step - accuracy: 0.7134 - loss: 0.7390\n",
2310
- "Epoch 146/250\n",
2311
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 82ms/step - accuracy: 0.7308 - loss: 0.7194\n",
2312
- "Epoch 147/250\n",
2313
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 95ms/step - accuracy: 0.7122 - loss: 0.7508\n",
2314
- "Epoch 148/250\n",
2315
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 138ms/step - accuracy: 0.7165 - loss: 0.7209\n",
2316
- "Epoch 149/250\n",
2317
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 81ms/step - accuracy: 0.7066 - loss: 0.7584\n",
2318
- "Epoch 150/250\n",
2319
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 83ms/step - accuracy: 0.6920 - loss: 0.7815\n",
2320
- "Epoch 151/250\n",
2321
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 92ms/step - accuracy: 0.6994 - loss: 0.7590\n",
2322
- "Epoch 152/250\n",
2323
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 92ms/step - accuracy: 0.7101 - loss: 0.7507\n",
2324
- "Epoch 153/250\n",
2325
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 84ms/step - accuracy: 0.6933 - loss: 0.7577\n",
2326
- "Epoch 154/250\n",
2327
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 81ms/step - accuracy: 0.6954 - loss: 0.7652\n",
2328
- "Epoch 155/250\n",
2329
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 97ms/step - accuracy: 0.7345 - loss: 0.6951\n",
2330
- "Epoch 156/250\n",
2331
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 89ms/step - accuracy: 0.7333 - loss: 0.7033\n",
2332
- "Epoch 157/250\n",
2333
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 85ms/step - accuracy: 0.7060 - loss: 0.7435\n",
2334
- "Epoch 158/250\n",
2335
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 92ms/step - accuracy: 0.7228 - loss: 0.7334\n",
2336
- "Epoch 159/250\n",
2337
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 102ms/step - accuracy: 0.6911 - loss: 0.7570\n",
2338
- "Epoch 160/250\n",
2339
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 98ms/step - accuracy: 0.7037 - loss: 0.7365\n",
2340
- "Epoch 161/250\n",
2341
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 86ms/step - accuracy: 0.6937 - loss: 0.7540\n",
2342
- "Epoch 162/250\n",
2343
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 102ms/step - accuracy: 0.7127 - loss: 0.7386\n",
2344
- "Epoch 163/250\n",
2345
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 99ms/step - accuracy: 0.7136 - loss: 0.6989\n",
2346
- "Epoch 164/250\n",
2347
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 89ms/step - accuracy: 0.7132 - loss: 0.6956\n",
2348
- "Epoch 165/250\n",
2349
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 96ms/step - accuracy: 0.7179 - loss: 0.7346\n",
2350
- "Epoch 166/250\n",
2351
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 137ms/step - accuracy: 0.7197 - loss: 0.7401\n",
2352
- "Epoch 167/250\n",
2353
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 118ms/step - accuracy: 0.7006 - loss: 0.7260\n",
2354
- "Epoch 168/250\n",
2355
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 90ms/step - accuracy: 0.7067 - loss: 0.7316\n",
2356
- "Epoch 169/250\n",
2357
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 89ms/step - accuracy: 0.7011 - loss: 0.7433\n",
2358
- "Epoch 170/250\n",
2359
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 77ms/step - accuracy: 0.7161 - loss: 0.7250\n",
2360
- "Epoch 171/250\n",
2361
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 106ms/step - accuracy: 0.6922 - loss: 0.7574\n",
2362
- "Epoch 172/250\n",
2363
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 99ms/step - accuracy: 0.7210 - loss: 0.7217\n",
2364
- "Epoch 173/250\n",
2365
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 95ms/step - accuracy: 0.7376 - loss: 0.6859\n",
2366
- "Epoch 174/250\n",
2367
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 95ms/step - accuracy: 0.6975 - loss: 0.7270\n",
2368
- "Epoch 175/250\n",
2369
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 98ms/step - accuracy: 0.6982 - loss: 0.7311\n",
2370
- "Epoch 176/250\n",
2371
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 85ms/step - accuracy: 0.7084 - loss: 0.7329\n",
2372
- "Epoch 177/250\n",
2373
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 87ms/step - accuracy: 0.7255 - loss: 0.6812\n",
2374
- "Epoch 178/250\n",
2375
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 96ms/step - accuracy: 0.7120 - loss: 0.6930\n",
2376
- "Epoch 179/250\n",
2377
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 98ms/step - accuracy: 0.7112 - loss: 0.7248\n",
2378
- "Epoch 180/250\n",
2379
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 85ms/step - accuracy: 0.7135 - loss: 0.7059\n",
2380
- "Epoch 181/250\n",
2381
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 90ms/step - accuracy: 0.7166 - loss: 0.7136\n",
2382
- "Epoch 182/250\n",
2383
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 83ms/step - accuracy: 0.7089 - loss: 0.6953\n",
2384
- "Epoch 183/250\n",
2385
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 84ms/step - accuracy: 0.7292 - loss: 0.6850\n",
2386
- "Epoch 184/250\n",
2387
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 89ms/step - accuracy: 0.7196 - loss: 0.6968\n",
2388
- "Epoch 185/250\n",
2389
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 84ms/step - accuracy: 0.7305 - loss: 0.6650\n",
2390
- "Epoch 186/250\n",
2391
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 81ms/step - accuracy: 0.7224 - loss: 0.7121\n",
2392
- "Epoch 187/250\n",
2393
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 83ms/step - accuracy: 0.7160 - loss: 0.7123\n",
2394
- "Epoch 188/250\n",
2395
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 83ms/step - accuracy: 0.7475 - loss: 0.6434\n",
2396
- "Epoch 189/250\n",
2397
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 84ms/step - accuracy: 0.7005 - loss: 0.6913\n",
2398
- "Epoch 190/250\n",
2399
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 84ms/step - accuracy: 0.7061 - loss: 0.7017\n",
2400
- "Epoch 191/250\n",
2401
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 74ms/step - accuracy: 0.7271 - loss: 0.6675\n",
2402
- "Epoch 192/250\n",
2403
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 82ms/step - accuracy: 0.7147 - loss: 0.6970\n",
2404
- "Epoch 193/250\n",
2405
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 86ms/step - accuracy: 0.7058 - loss: 0.7192\n",
2406
- "Epoch 194/250\n",
2407
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 83ms/step - accuracy: 0.7208 - loss: 0.6875\n",
2408
- "Epoch 195/250\n",
2409
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 82ms/step - accuracy: 0.7014 - loss: 0.7021\n",
2410
- "Epoch 196/250\n",
2411
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 80ms/step - accuracy: 0.7102 - loss: 0.7148\n",
2412
- "Epoch 197/250\n",
2413
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 77ms/step - accuracy: 0.7114 - loss: 0.7243\n",
2414
- "Epoch 198/250\n",
2415
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 105ms/step - accuracy: 0.7312 - loss: 0.6636\n",
2416
- "Epoch 199/250\n",
2417
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 82ms/step - accuracy: 0.7310 - loss: 0.6885\n",
2418
- "Epoch 200/250\n",
2419
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 83ms/step - accuracy: 0.7009 - loss: 0.7219\n",
2420
- "Epoch 201/250\n",
2421
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 89ms/step - accuracy: 0.7246 - loss: 0.6865\n",
2422
- "Epoch 202/250\n",
2423
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 81ms/step - accuracy: 0.7178 - loss: 0.6881\n",
2424
- "Epoch 203/250\n",
2425
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 82ms/step - accuracy: 0.6878 - loss: 0.7230\n",
2426
- "Epoch 204/250\n",
2427
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 85ms/step - accuracy: 0.6909 - loss: 0.7563\n",
2428
- "Epoch 205/250\n",
2429
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 77ms/step - accuracy: 0.7285 - loss: 0.6559\n",
2430
- "Epoch 206/250\n",
2431
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 81ms/step - accuracy: 0.7008 - loss: 0.6901\n",
2432
- "Epoch 207/250\n",
2433
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 78ms/step - accuracy: 0.6892 - loss: 0.7049\n",
2434
- "Epoch 208/250\n",
2435
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 78ms/step - accuracy: 0.6967 - loss: 0.7165\n",
2436
- "Epoch 209/250\n",
2437
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 85ms/step - accuracy: 0.6967 - loss: 0.7154\n",
2438
- "Epoch 210/250\n",
2439
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 76ms/step - accuracy: 0.7229 - loss: 0.6803\n",
2440
- "Epoch 211/250\n",
2441
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 82ms/step - accuracy: 0.7196 - loss: 0.6776\n",
2442
- "Epoch 212/250\n",
2443
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 96ms/step - accuracy: 0.7095 - loss: 0.6821\n",
2444
- "Epoch 213/250\n",
2445
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 90ms/step - accuracy: 0.7053 - loss: 0.6740\n",
2446
- "Epoch 214/250\n",
2447
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 82ms/step - accuracy: 0.7222 - loss: 0.6821\n",
2448
- "Epoch 215/250\n",
2449
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 81ms/step - accuracy: 0.7203 - loss: 0.6606\n",
2450
- "Epoch 216/250\n",
2451
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 83ms/step - accuracy: 0.6984 - loss: 0.7023\n",
2452
- "Epoch 217/250\n",
2453
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 79ms/step - accuracy: 0.6968 - loss: 0.6922\n",
2454
- "Epoch 218/250\n",
2455
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 88ms/step - accuracy: 0.6963 - loss: 0.6859\n",
2456
- "Epoch 219/250\n",
2457
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 83ms/step - accuracy: 0.7408 - loss: 0.6773\n",
2458
- "Epoch 220/250\n",
2459
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 81ms/step - accuracy: 0.7197 - loss: 0.6975\n",
2460
- "Epoch 221/250\n",
2461
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 78ms/step - accuracy: 0.6944 - loss: 0.7280\n",
2462
- "Epoch 222/250\n",
2463
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 79ms/step - accuracy: 0.7116 - loss: 0.6936\n",
2464
- "Epoch 223/250\n",
2465
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 74ms/step - accuracy: 0.6943 - loss: 0.6861\n",
2466
- "Epoch 224/250\n",
2467
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 84ms/step - accuracy: 0.6901 - loss: 0.7022\n",
2468
- "Epoch 225/250\n",
2469
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 98ms/step - accuracy: 0.7078 - loss: 0.6871\n",
2470
- "Epoch 226/250\n",
2471
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 82ms/step - accuracy: 0.7117 - loss: 0.6798\n",
2472
- "Epoch 227/250\n",
2473
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 70ms/step - accuracy: 0.7056 - loss: 0.6796\n",
2474
- "Epoch 228/250\n",
2475
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 77ms/step - accuracy: 0.7203 - loss: 0.6729\n",
2476
- "Epoch 229/250\n",
2477
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 81ms/step - accuracy: 0.7013 - loss: 0.6922\n",
2478
- "Epoch 230/250\n",
2479
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 78ms/step - accuracy: 0.7239 - loss: 0.6664\n",
2480
- "Epoch 231/250\n",
2481
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 80ms/step - accuracy: 0.7274 - loss: 0.6656\n",
2482
- "Epoch 232/250\n",
2483
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 73ms/step - accuracy: 0.7247 - loss: 0.6782\n",
2484
- "Epoch 233/250\n",
2485
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 77ms/step - accuracy: 0.7108 - loss: 0.6607\n",
2486
- "Epoch 234/250\n",
2487
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 80ms/step - accuracy: 0.7120 - loss: 0.6636\n",
2488
- "Epoch 235/250\n",
2489
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 78ms/step - accuracy: 0.7343 - loss: 0.6851\n",
2490
- "Epoch 236/250\n",
2491
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 82ms/step - accuracy: 0.7196 - loss: 0.6570\n",
2492
- "Epoch 237/250\n",
2493
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 77ms/step - accuracy: 0.7121 - loss: 0.6956\n",
2494
- "Epoch 238/250\n",
2495
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 83ms/step - accuracy: 0.7130 - loss: 0.6634\n",
2496
- "Epoch 239/250\n",
2497
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 75ms/step - accuracy: 0.7217 - loss: 0.6661\n",
2498
- "Epoch 240/250\n",
2499
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 87ms/step - accuracy: 0.7023 - loss: 0.6885\n",
2500
- "Epoch 241/250\n",
2501
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 79ms/step - accuracy: 0.6849 - loss: 0.7162\n",
2502
- "Epoch 242/250\n",
2503
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 83ms/step - accuracy: 0.7219 - loss: 0.6764\n",
2504
- "Epoch 243/250\n",
2505
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 81ms/step - accuracy: 0.7349 - loss: 0.6531\n",
2506
- "Epoch 244/250\n",
2507
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 80ms/step - accuracy: 0.7226 - loss: 0.6812\n",
2508
- "Epoch 245/250\n",
2509
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 78ms/step - accuracy: 0.7014 - loss: 0.6809\n",
2510
- "Epoch 246/250\n",
2511
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 85ms/step - accuracy: 0.7247 - loss: 0.6708\n",
2512
- "Epoch 247/250\n",
2513
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 90ms/step - accuracy: 0.7133 - loss: 0.6595\n",
2514
- "Epoch 248/250\n",
2515
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 78ms/step - accuracy: 0.7096 - loss: 0.6751\n",
2516
- "Epoch 249/250\n",
2517
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 95ms/step - accuracy: 0.7137 - loss: 0.6694\n",
2518
- "Epoch 250/250\n",
2519
- "\u001b[1m2/2\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m0s\u001b[0m 104ms/step - accuracy: 0.6997 - loss: 0.6777\n"
2520
- ]
2521
- },
2522
- {
2523
- "data": {
2524
- "text/plain": [
2525
- "<keras.src.callbacks.history.History at 0x298c8d76d80>"
2526
- ]
2527
- },
2528
- "execution_count": 48,
2529
- "metadata": {},
2530
- "output_type": "execute_result"
2531
- }
2532
- ],
2533
- "source": [
2534
- "# Train the model\n",
2535
- "model.fit(source_sequences, target_sequences_one_hot,batch_size = 64, epochs=250)"
2536
- ]
2537
- },
2538
- {
2539
- "cell_type": "code",
2540
- "execution_count": 49,
2541
- "id": "1c136c15",
2542
- "metadata": {},
2543
- "outputs": [
2544
- {
2545
- "name": "stdin",
2546
- "output_type": "stream",
2547
- "text": [
2548
- "Enter String : Thanks\n"
2549
- ]
2550
- },
2551
- {
2552
- "name": "stdout",
2553
- "output_type": "stream",
2554
- "text": [
2555
- "\u001b[1m1/1\u001b[0m \u001b[32m━━━━━━━━━━━━━━━━━━━━\u001b[0m\u001b[37m\u001b[0m \u001b[1m1s\u001b[0m 1s/step\n",
2556
- "Input Sequence: Thanks\n",
2557
- "Translated Sequence: Gracias!\n"
2558
- ]
2559
- }
2560
- ],
2561
- "source": [
2562
- "# Translate a new input sequence\n",
2563
- "x = input(\"Enter String : \")\n",
2564
- "input_sequence = x\n",
2565
- "input_sequence = [source_char_to_int[char] for char in input_sequence]\n",
2566
- "input_sequence = tf.keras.preprocessing.sequence.pad_sequences([input_sequence], maxlen=max_sequence_length, padding='post')\n",
2567
- "output_sequence = model.predict(input_sequence)[0]\n",
2568
- "# Decode the output sequence\n",
2569
- "output_sequence = [target_int_to_char[np.argmax(char)] for char in output_sequence]\n",
2570
- "print(\"Input Sequence:\",x)\n",
2571
- "print(\"Translated Sequence:\", ''.join(output_sequence))"
2572
- ]
2573
- },
2574
- {
2575
- "cell_type": "markdown",
2576
- "id": "d4f776f9",
2577
- "metadata": {},
2578
- "source": [
2579
- "<hr style=\"height:10px;border-width:0;background-color:teal\">"
2580
- ]
2581
- }
2582
- ],
2583
- "metadata": {
2584
- "kaggle": {
2585
- "accelerator": "none",
2586
- "dataSources": [
2587
- {
2588
- "datasetId": 5923474,
2589
- "sourceId": 9689378,
2590
- "sourceType": "datasetVersion"
2591
- }
2592
- ],
2593
- "dockerImageVersionId": 30786,
2594
- "isGpuEnabled": false,
2595
- "isInternetEnabled": true,
2596
- "language": "python",
2597
- "sourceType": "notebook"
2598
- },
2599
- "kernelspec": {
2600
- "display_name": "Python 3 (ipykernel)",
2601
- "language": "python",
2602
- "name": "python3"
2603
- },
2604
- "language_info": {
2605
- "codemirror_mode": {
2606
- "name": "ipython",
2607
- "version": 3
2608
- },
2609
- "file_extension": ".py",
2610
- "mimetype": "text/x-python",
2611
- "name": "python",
2612
- "nbconvert_exporter": "python",
2613
- "pygments_lexer": "ipython3",
2614
- "version": "3.12.4"
2615
- }
2616
- },
2617
- "nbformat": 4,
2618
- "nbformat_minor": 5
2619
- }