Sentiment Classification
[ Getting Started Notebook ] Sentiment Classification
A getting started notebook for the challenge.
Getting Started with Sentiment Classification
In this puzzle, we have to classify the sentiment into 3 classes, positive, negative and neutral from the given features of an human face.
This is a starter kit explaining how to download the data and also submit direcly via this notebook.
We will be submitting the sample prediction directly in the required format.
In [ ]:
!pip install aicrowd-cli
%load_ext aicrowd.magic
Login to AIcrowd ㊗¶¶
In [ ]:
%aicrowd login
Download Dataset¶¶
We will create a folder name data and download the files there.
In [ ]:
!rm -rf data
!mkdir data
%aicrowd ds dl -c sentiment-classification -o data
Importing Libraries:¶
In [ ]:
import pandas as pd
import numpy as np
import os
Diving in the dataset 🕵️♂️¶
In [ ]:
train_df = pd.read_csv("data/train.csv")
val_df = pd.read_csv("data/val.csv")
In [ ]:
test_df = pd.read_csv("data/test.csv")
Generating Prediction File¶
In this starter kit we will directly be submitting the sample prediction file. In case you would like to see a submission via baseline model, check it out here.
In [ ]:
submission = pd.read_csv('data/sample_submission.csv')
In [ ]:
!rm -rf assets
!mkdir assets
submission.to_csv(os.path.join("assets", "submission.csv"))
Submitting our Predictions¶
Note : Please save the notebook before submitting it (Ctrl + S)
In [ ]:
%aicrowd notebook submit -c sentiment-classification -a assets --no-verify
Content
Comments
You must login before you can post a comment.