Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/cmusphinx/g2p-seq2seq
/ functions
Functions
71 in github.com/cmusphinx/g2p-seq2seq
⨍
Functions
71
◇
Types & classes
6
↓ 11 callers
Method
decode
Run decoding mode.
g2p_seq2seq/g2p.py:285
↓ 7 callers
Method
encode
(self, symbols_line)
g2p_seq2seq/g2p_encoder.py:67
↓ 4 callers
Method
generator
Generator for the training and evaluation data. Generate source and target data from a single file. Args: data_path: The path to data f
g2p_seq2seq/g2p_problem.py:77
↓ 3 callers
Method
__prepare_model
Prepare utilities for decoding.
g2p_seq2seq/g2p.py:92
↓ 3 callers
Method
__run_op
Run tensorflow operation for decoding.
g2p_seq2seq/g2p.py:249
↓ 3 callers
Function
collect_pronunciations
Create dictionary mapping word to its different pronounciations. Args: source_path: path to the data file; cleanup: flag indicating whether
g2p_seq2seq/g2p_problem.py:457
↓ 3 callers
Function
save_dic
(dic, save_path)
g2p_seq2seq/g2p_problem.py:516
↓ 2 callers
Method
__decode_from_file
Compute predictions on entries in filename and write them out.
g2p_seq2seq/g2p.py:415
↓ 2 callers
Method
_init_vocab
Initialize vocabulary with sym from sym_generator.
g2p_seq2seq/g2p_encoder.py:122
↓ 2 callers
Method
calc_errors
Calculate a number of prediction errors.
g2p_seq2seq/g2p.py:481
↓ 2 callers
Method
evaluate
Run evaluation mode.
g2p_seq2seq/g2p.py:302
↓ 2 callers
Function
gen_file
Generate cases from generator and save as TFRecord file. Args: generator: a generator yielding (string -> int/float/str list) data. output_
g2p_seq2seq/g2p_problem.py:366
↓ 2 callers
Function
get_word
Get next word in the interactive mode.
g2p_seq2seq/g2p.py:506
↓ 2 callers
Function
split_graphemes_phonemes
Split line into graphemes and phonemes. Args: input_line: raw input line; cleanup: flag indicating whether to cleanup datasets from stress
g2p_seq2seq/g2p_problem.py:487
↓ 2 callers
Method
train
Run training.
g2p_seq2seq/g2p.py:255
↓ 1 callers
Method
__init__
Initialize generator.
g2p_seq2seq/g2p_problem.py:319
↓ 1 callers
Method
__interactive_input_fn
(self)
g2p_seq2seq/g2p.py:228
↓ 1 callers
Method
__load_graph
Load freezed graph.
g2p_seq2seq/g2p.py:401
↓ 1 callers
Method
__prepare_interactive_model
Create monitored session and generator that reads from the terminal and yields "interactive inputs". Due to temporary limitations in tf.learn
g2p_seq2seq/g2p.py:118
↓ 1 callers
Function
_decode_batch_input_fn
Decode batch
g2p_seq2seq/g2p.py:557
↓ 1 callers
Function
_get_inputs
Returning inputs. Args: filename: path to file with inputs, 1 per line. delimiters: str, delimits records in the file. Returns: a li
g2p_seq2seq/g2p.py:531
↓ 1 callers
Method
_init_vocab_from_file
Load vocab from a file. Args: filename: The file to load vocabulary from.
g2p_seq2seq/g2p_encoder.py:90
↓ 1 callers
Method
_init_vocab_from_list
Initialize symbols from a list of symbols. It is ok if reserved symbols appear in the vocab list. They will be removed. The set of symbols in
g2p_seq2seq/g2p_encoder.py:105
↓ 1 callers
Function
add_problem_hparams
Add problem hparams for the problems.
g2p_seq2seq/g2p_trainer_utils.py:43
↓ 1 callers
Function
build_vocab_list
Reads a file to build a vocabulary with letters and phonemes. Args: data_path: data file to read list of words from. Returns: vo
g2p_seq2seq/g2p_encoder.py:152
↓ 1 callers
Function
create_data_files
Create train, development and test data files from initial data files in case when not provided development or test data files or active cleanup f
g2p_seq2seq/g2p_problem.py:380
↓ 1 callers
Function
create_experiment
Create Experiment.
g2p_seq2seq/g2p_trainer_utils.py:84
↓ 1 callers
Function
create_experiment_func
Wrapper for canonical experiment_fn. See create_experiment.
g2p_seq2seq/g2p_trainer_utils.py:75
↓ 1 callers
Function
create_g2p_gt_map
Create grapheme-to-phoneme ground true mapping.
g2p_seq2seq/g2p.py:520
↓ 1 callers
Method
decode_list
(self, ids)
g2p_seq2seq/g2p_encoder.py:83
↓ 1 callers
Method
decode_word
Decode word. Args: word: word for decoding. Returns: pronunciation: a decoded phonemes sequence for input word.
g2p_seq2seq/g2p.py:186
↓ 1 callers
Function
execute_schedule
(exp, params)
g2p_seq2seq/g2p.py:585
↓ 1 callers
Method
feature_encoders
(self)
g2p_seq2seq/g2p_problem.py:156
↓ 1 callers
Method
filepattern
(self, data_dir, dataset_split, shard=None)
g2p_seq2seq/g2p_problem.py:94
↓ 1 callers
Method
freeze
Freeze pre-trained model.
g2p_seq2seq/g2p.py:331
↓ 1 callers
Method
generate_preprocess_data
Generate and save preprocessed data as TFRecord files. Args: train_path: the path to the train data file. eval_path: the path to the
g2p_seq2seq/g2p_problem.py:127
↓ 1 callers
Function
generate_preprocess_files
Generate cases from a generators and save as TFRecord files. Generated cases are transformed to tf.Example protos and saved as TFRecords in shard
g2p_seq2seq/g2p_problem.py:331
↓ 1 callers
Method
interactive
Interactive decoding.
g2p_seq2seq/g2p.py:260
↓ 1 callers
Function
profile_context
(params)
g2p_seq2seq/g2p.py:594
↓ 1 callers
Method
store_to_file
Write vocab file to disk. Vocab files have one symbol per line. The file ends in a newline. Reserved symbols are written to the vocab file as
g2p_seq2seq/g2p_encoder.py:138
↓ 1 callers
Method
tabbed_generator
r"""Generator for sequence-to-sequence tasks using tabbed files. Tokens are derived from text files where each line contains both a source an
g2p_seq2seq/g2p_problem.py:163
Method
__call__
(self)
g2p_seq2seq/g2p_problem.py:323
Method
__init__
Create a Problem. Args: was_reversed: bool, whether to reverse inputs and targets. was_copy: bool, whether to copy inputs to targets.
g2p_seq2seq/g2p_problem.py:43
Method
__init__
(self, model_dir, data_path, flags=None)
g2p_seq2seq/params.py:25
Method
__init__
Initialize from a file or list, one token per line. Handling of reserved tokens works as follows: - When initializing from a list, we add res
g2p_seq2seq/g2p_encoder.py:38
Method
__init__
(self, params, train_path="", dev_path="", test_path="", cleanup=False, p2g_mode=False)
g2p_seq2seq/g2p.py:55
Method
_preprocess
Whether preprocess data into required format.
g2p_seq2seq/g2p_problem.py:295
Function
create_experiment_fn
(params, problem_instance)
g2p_seq2seq/g2p_trainer_utils.py:50
Function
create_run_config
Create RunConfig
g2p_seq2seq/g2p_trainer_utils.py:203
Method
dataset
Build a Dataset for this problem. Args: mode: tf.estimator.ModeKeys; determines which files to read from. data_dir: directory that co
g2p_seq2seq/g2p_problem.py:198
Method
decode
(self, ids)
g2p_seq2seq/g2p_encoder.py:80
Method
decode_record
Serialized Example to dict of <feature name, Tensor>.
g2p_seq2seq/g2p_problem.py:286
Function
experiment_fn
(run_config, hparams)
g2p_seq2seq/g2p_trainer_utils.py:78
Method
get_feature_encoders
(self, data_dir=None)
g2p_seq2seq/g2p_problem.py:151
Method
input_fn
Input function returning features which is a dictionary of string feature name to `Tensor` or `SparseTensor`. If it returns a tuple, f
g2p_seq2seq/g2p.py:134
Method
input_space_id
(self)
g2p_seq2seq/g2p_problem.py:100
Method
is_character_level
(self)
g2p_seq2seq/g2p_problem.py:116
Function
load_create_vocabs
Load/create vocabularies.
g2p_seq2seq/g2p_encoder.py:176
Function
load_params
Load customizable parameters from 'model.params' file.
g2p_seq2seq/g2p_trainer_utils.py:248
Function
main
Main function.
g2p_seq2seq/app.py:90
Method
num_shards
(self)
g2p_seq2seq/g2p_problem.py:108
Function
save_params
Save customizable model parameters in 'model.params' file.
g2p_seq2seq/g2p_trainer_utils.py:232
Method
sym_gen
Symbols generator for vocab initializer from file.
g2p_seq2seq/g2p_encoder.py:96
Method
target_space_id
(self)
g2p_seq2seq/g2p_problem.py:104
Method
targeted_vocab_size
(self)
g2p_seq2seq/g2p_problem.py:120
Method
test_decode
(self)
tests/g2p_unittest.py:28
Method
test_evaluate
(self)
tests/g2p_unittest.py:42
Method
test_train
(self)
tests/g2p_unittest.py:14
Method
use_subword_tokenizer
(self)
g2p_seq2seq/g2p_problem.py:112
Method
vocab_name
(self)
g2p_seq2seq/g2p_problem.py:124
Method
vocab_size
(self)
g2p_seq2seq/g2p_encoder.py:87