(self, index)
return sentence, conversation_length, sentence_length
Return Single data sentence
Return Single data sentence
Return Single data sentence
def __getitem__(self, index):
        """Return Single data sentence"""
        # [max_conversation_length, max_sentence_length]
        sentence = self.sentences[index]
        conversation_length = self.conversation_length[index]
        sentence_length = self.sentence_length[index]

        # word => word_ids
        sentence = self.sent2id(sentence)

        return sentence, conversation_length, sentence_length
def __getitem__ ( self , index ) : # [max_conversation_length, max_sentence_length] sentence = self . sentences [ index ] conversation_length = self . conversation_length [ index ] sentence_length = self . sentence_length [ index ] # word => word_ids sentence = self . sent2id ( sentence ) return sentence , conversation_length , sentence_length