रेगुलर सीज़न के ट्रेनिंग डेटा पर मॉडल फिट करें
अब जब आपने एक पूरा टीम स्ट्रेंथ मॉडल परिभाषित कर लिया है, तो आप इसे बास्केटबॉल डेटा पर फिट कर सकते हैं! चूँकि आपके मॉडल में अब दो इनपुट हैं, इसलिए आपको इनपुट डेटा को एक सूची के रूप में पास करना होगा.
यह अभ्यास पाठ्यक्रम का हिस्सा है
Keras के साथ Advanced Deep Learning
अभ्यास निर्देश
games_seasonसे'team_1'और'team_2'कॉलम को क्रमशःinput_1औरinput_2में असाइन करें.- टारगेट के रूप में
games_seasonका'score_diff'कॉलम उपयोग करें. - मॉडल को 1 epoch, batch size 2048, और 10% validation split के साथ फिट करें.
इंटरैक्टिव व्यावहारिक अभ्यास
इस अभ्यास को इस नमूना कोड को पूरा करके आज़माएँ।
# Get the team_1 column from the regular season data
input_1 = games_season[___]
# Get the team_2 column from the regular season data
input_2 = games_season[___]
# Fit the model to input 1 and 2, using score diff as a target
____(____,
____,
epochs=____,
batch_size=____,
validation_split=____,
verbose=True)