#include <fstream>
#include <iostream>
#include <vector>
#include <sstream>
#include <map>
#include <set>
#include <cstdlib>
Go to the source code of this file.
Functions | |
int | stringToInteger (string s) |
void | loadInput (const char *fileName, vector< string > &input) |
void | getWords (string s, vector< string > &currInput) |
string | getTranslation (int index, vector< pair< string, vector< int > > > &gCepts, vector< string > &currF, map< string, int > &singletons) |
int | closestGap (map< int, string > gap, int j1, int &gp) |
void | generateStory (vector< pair< string, vector< int > > > &gCepts, set< int > &targetNullWords, vector< string > &currF, map< string, int > &singletons) |
void | ceptsInGenerativeStoryFormat (vector< pair< set< int >, set< int > > > &ceptsInPhrase, vector< pair< string, vector< int > > > &gCepts, set< int > &sourceNullWords, vector< string > &currE) |
void | printCepts (vector< pair< string, vector< int > > > &gCepts, vector< string > &currF) |
void | getMeCepts (set< int > &eSide, set< int > &fSide, map< int, vector< int > > &tS, map< int, vector< int > > &sT) |
void | constructCepts (vector< pair< set< int >, set< int > > > &ceptsInPhrase, set< int > &sourceNullWords, set< int > &targetNullWords, vector< string > &alignment, int eSize, int fSize) |
int | main (int argc, char *argv[]) |
void ceptsInGenerativeStoryFormat | ( | vector< pair< set< int >, set< int > > > & | ceptsInPhrase, | |
vector< pair< string, vector< int > > > & | gCepts, | |||
set< int > & | sourceNullWords, | |||
vector< string > & | currE | |||
) |
Definition at line 245 of file GenerateSequences.cpp.
Referenced by main().
int closestGap | ( | map< int, string > | gap, | |
int | j1, | |||
int & | gp | |||
) |
Definition at line 82 of file GenerateSequences.cpp.
Referenced by generateStory().
void constructCepts | ( | vector< pair< set< int >, set< int > > > & | ceptsInPhrase, | |
set< int > & | sourceNullWords, | |||
set< int > & | targetNullWords, | |||
vector< string > & | alignment, | |||
int | eSize, | |||
int | fSize | |||
) |
Definition at line 387 of file GenerateSequences.cpp.
References getMeCepts(), src, and stringToInteger().
void generateStory | ( | vector< pair< string, vector< int > > > & | gCepts, | |
set< int > & | targetNullWords, | |||
vector< string > & | currF, | |||
map< string, int > & | singletons | |||
) |
Definition at line 127 of file GenerateSequences.cpp.
References closestGap(), getTranslation(), and k.
Referenced by main().
void getMeCepts | ( | set< int > & | eSide, | |
set< int > & | fSide, | |||
map< int, vector< int > > & | tS, | |||
map< int, vector< int > > & | sT | |||
) |
Definition at line 355 of file GenerateSequences.cpp.
References getMeCepts().
string getTranslation | ( | int | index, | |
vector< pair< string, vector< int > > > & | gCepts, | |||
vector< string > & | currF, | |||
map< string, int > & | singletons | |||
) |
Definition at line 55 of file GenerateSequences.cpp.
Referenced by generateStory().
void getWords | ( | string | s, | |
vector< string > & | currInput | |||
) |
Definition at line 41 of file GenerateSequences.cpp.
void loadInput | ( | const char * | fileName, | |
vector< string > & | input | |||
) |
Definition at line 22 of file GenerateSequences.cpp.
int main | ( | int | argc, | |
char * | argv[] | |||
) |
Definition at line 458 of file GenerateSequences.cpp.
References ceptsInGenerativeStoryFormat(), constructCepts(), generateStory(), getWords(), and loadInput().
void printCepts | ( | vector< pair< string, vector< int > > > & | gCepts, | |
vector< string > & | currF | |||
) |
Definition at line 332 of file GenerateSequences.cpp.
int stringToInteger | ( | string | s | ) |
Definition at line 13 of file GenerateSequences.cpp.