(self, file_path)
Save Vocab to file as JSON dump.
        @param file_path (str): file path to vocab file
Save Vocab to file as JSON dump.
Save Vocab to file as JSON dump .
def save(self, file_path):
        """ Save Vocab to file as JSON dump.
        @param file_path (str): file path to vocab file
        """
        json.dump(dict(src_word2id=self.src.word2id, tgt_word2id=self.tgt.word2id), open(file_path, 'w'), indent=2)
def save ( self , file_path ) : json . dump ( dict ( src_word2id = self . src . word2id , tgt_word2id = self . tgt . word2id ) , open ( file_path , 'w' ) , indent = 2 )