Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/XiangLi1999/syntactic-VIB
/ functions
Functions
199 in github.com/XiangLi1999/syntactic-VIB
⨍
Functions
199
◇
Types & classes
23
↓ 16 callers
Method
forward_sent
used for some evaluation scripts, not for training
src/gaussian_tag.py:41
↓ 14 callers
Method
parse_dev_batch
(self, corpus, out_path)
src/baselines.py:247
↓ 13 callers
Method
_test_ok
(self, gold, system, correct)
src/utils/evaluation_script/conll17_ud_eval.py:529
↓ 12 callers
Method
forward
Parameters ---------- words : Dict[str, torch.LongTensor], required The output of ``TextField.as_array()``, which
src/allen_parser.py:159
↓ 12 callers
Function
svm_eval
(gamma_lst, X, y)
src/experiment_helper.py:342
↓ 11 callers
Method
_get_embeddings
(self, sent_lst)
src/conllu_handler.py:375
↓ 10 callers
Function
load_elmo
(data_loader, args, embed_loader, mod='train', processed_sent_dev=None, processed_sent_test=None)
src/others.py:2
↓ 9 callers
Function
alignment_score
(alignment, key_fn, weight_fn=lambda w: 1)
src/utils/evaluation_script/conll17_ud_eval.py:285
↓ 8 callers
Method
elmo_embeddings_first
(self, processed_sent, number_sent, store_file=None)
src/conllu_handler.py:540
↓ 8 callers
Method
load_dev
(self, dataset_dev_path)
src/conllu_handler.py:48
↓ 8 callers
Method
load_dev_verbo
(self, dataset_dev_path)
src/conllu_handler.py:57
↓ 7 callers
Method
parse_dev_batch
(self, corpus, elmo_embeds, non_context_embeds, out_path)
src/discrete_tag.py:269
↓ 6 callers
Function
dev_token_loader_batch
(dev_sent, embed_loader, dim=1)
src/experiment_helper.py:73
↓ 6 callers
Method
load_dev_with_tags
(self, dataset_dev_path)
src/conllu_handler.py:66
↓ 6 callers
Function
name_map2embed
(name_map, embeds)
src/experiment_helper.py:514
↓ 6 callers
Method
save_model
(self, path)
src/baselines.py:355
↓ 6 callers
Method
train
(self, x_lst, data, sent_per_epoch)
src/baselines.py:54
↓ 4 callers
Method
__init__
(self, tag_dict, options)
src/baselines.py:205
↓ 4 callers
Method
_is_projective
Checks if a dependency graph is projective
src/conllu_handler.py:190
↓ 4 callers
Method
_is_projective
Checks if a dependency graph is projective
src/conllu_handler.py:823
↓ 4 callers
Function
_load_data
()
src/main.py:42
↓ 4 callers
Method
_load_words
Prepare fake CoNLL-U files with fake HEAD to prevent multiple roots errors.
src/utils/evaluation_script/conll17_ud_eval.py:511
↓ 4 callers
Function
_start_
()
src/main.py:26
↓ 4 callers
Function
dev_token_loader
(dev_path, dev_sent, embed_loader, dim=1)
src/others.py:88
↓ 4 callers
Method
elmo_embeddings
(self, processed_sent, number_sent, lang='en', args=None)
src/conllu_handler.py:506
↓ 4 callers
Function
get_stem
(processed_sent, stemmer, stem_dict)
src/experiment_helper.py:193
↓ 4 callers
Function
lower
(text)
src/utils/evaluation_script/conll17_ud_eval.py:266
↓ 4 callers
Method
parse_dev
(self, x_lst, data)
src/baselines.py:110
↓ 4 callers
Method
pre_process_data_
(self, path)
src/conllu_handler.py:138
↓ 4 callers
Method
pre_process_data_
(self, path)
src/conllu_handler.py:771
↓ 4 callers
Function
transitive_data_process
( x_lst, tag_lst, tree_lst, edge_lst)
src/experiment_helper.py:520
↓ 3 callers
Method
apply_dict
(self, dev_data)
src/conllu_handler.py:332
↓ 3 callers
Method
apply_dict
(self, dev_data)
src/conllu_handler.py:965
↓ 3 callers
Method
elmo_embeddings_first_batch
(batch, sequence_length, 50) returns dict
src/conllu_handler.py:487
↓ 3 callers
Method
get_tree_dev
(self, train_data)
src/conllu_handler.py:260
↓ 3 callers
Method
get_tree_dev
(self, train_data)
src/conllu_handler.py:893
↓ 3 callers
Function
load_elmo_batch
(data_loader, args, embed_loader, mod='train', processed_sent_dev=None, processed_sent_test=None)
src/experiment_helper.py:14
↓ 3 callers
Method
load_model
(self, path)
src/baselines.py:359
↓ 3 callers
Function
train_token_loader_batch
(data_loader, embed_loader, dim=1)
src/experiment_helper.py:80
↓ 2 callers
Method
__setattr__
(self, key, value)
src/glo.py:64
↓ 2 callers
Method
_construct_loss
Computes the arc and tag loss for a sequence given gold head indices and tags. Parameters ---------- head_tag_repres
src/allen_parser.py:326
↓ 2 callers
Method
_get_head_tags
Decodes the head tags given the head and child tag representations and a tensor of head indices to compute tags for. Note that these
src/allen_parser.py:554
↓ 2 callers
Function
_load_pretrain_emb
(data_loader, en_batch_dev = None, en_batch_test=None)
src/main.py:69
↓ 2 callers
Method
add
(self, dict)
src/glo.py:76
↓ 2 callers
Method
append_aligned_words
(self, gold_word, system_word)
src/utils/evaluation_script/conll17_ud_eval.py:253
↓ 2 callers
Method
batchify
(self, corpus, bsz)
src/conllu_handler.py:646
↓ 2 callers
Function
beyond_end
(words, i, multiword_span_end)
src/utils/evaluation_script/conll17_ud_eval.py:307
↓ 2 callers
Method
compute_y_t_batch
this is a variational bound. q(y|t) namely the decoder. This returns a log-probability, total_error_number, and t
src/discrete_tag.py:176
↓ 2 callers
Method
compute_y_t_batch
this is a variational bound. q(y|t) namely the decoder. This returns a log-probability, total_error_number, and t
src/gaussian_tag.py:169
↓ 2 callers
Method
compute_y_t_batch
this is a variational bound. q(y|t) namely the decoder. This returns a log-probability, total_error_number, and t
src/baselines.py:182
↓ 2 callers
Method
eval_dev_discrete
(self, word_lst, pos_lst, elmo_train)
src/baselines.py:750
↓ 2 callers
Function
evaluate
(gold_ud, system_ud, deprel_weights=None)
src/utils/evaluation_script/conll17_ud_eval.py:234
↓ 2 callers
Function
extend_end
(word, multiword_span_end)
src/utils/evaluation_script/conll17_ud_eval.py:314
↓ 2 callers
Function
fetch_paths
(lang)
src/lang_select.py:21
↓ 2 callers
Method
forward_batch
(self, sample_sentence, sample_tag = None, type_embeds=None, non_context_embeds=None)
src/discrete_tag.py:201
↓ 2 callers
Method
forward_batch
(self, sample_sentence, sample_tag = None, type_embeds=None, non_context_embeds=None)
src/gaussian_tag.py:189
↓ 2 callers
Method
forward_batch
(self, sample_sentence, tags=None)
src/baselines.py:237
↓ 2 callers
Method
forward_batch
(self, sample_sentence, embeds=None)
src/baselines.py:405
↓ 2 callers
Function
get_logger
(level=logging.INFO)
src/glo.py:15
↓ 2 callers
Method
get_part_elmo
(self, batch_)
src/conllu_handler.py:399
↓ 2 callers
Method
get_sample_from_param_batch
(self, alpha, sample_size)
src/discrete_tag.py:80
↓ 2 callers
Method
get_statistics_batch
(self, sent, elmo_embeds)
src/discrete_tag.py:72
↓ 2 callers
Method
get_statistics_batch
(self, sent, elmo_embeds)
src/gaussian_tag.py:75
↓ 2 callers
Method
kl_div
(self, alpha1, alpha2)
src/discrete_tag.py:169
↓ 2 callers
Method
kl_div
Calculates the KL divergence between a categorical distribution and a uniform categorical distribution. Parameters --
src/gaussian_tag.py:140
↓ 2 callers
Function
load_conllu
(file)
src/utils/evaluation_script/conll17_ud_eval.py:99
↓ 2 callers
Function
load_conllu_file
(path)
src/utils/evaluation_script/conll17_ud_eval.py:451
↓ 2 callers
Function
main
(args)
src/main.py:872
↓ 2 callers
Method
save_model
(self, path)
src/discrete_tag.py:425
↓ 2 callers
Function
spans_score
(gold_spans, system_spans)
src/utils/evaluation_script/conll17_ud_eval.py:271
↓ 2 callers
Method
tag2embeddings
(self, tags)
src/discrete_tag.py:197
↓ 2 callers
Method
train_batch
(self, corpus)
src/baselines.py:301
↓ 2 callers
Function
train_token_loader
(train_data_path, data_loader, embed_loader, dim=1)
src/others.py:71
↓ 1 callers
Method
__init__
(self, options, word_dict)
src/discrete_tag.py:112
↓ 1 callers
Method
__init__
(self, options, word_dict)
src/gaussian_tag.py:86
↓ 1 callers
Method
_get_mask_for_eval
Dependency evaluation excludes words are punctuation. Here, we create a new mask to exclude word indices which have a "punctu
src/allen_parser.py:613
↓ 1 callers
Method
_getattr_
(obj, key)
src/glo.py:53
↓ 1 callers
Method
_greedy_decode
Decodes the head and head tag predictions by decoding the unlabeled arcs independently for each word and then again, predicting the h
src/allen_parser.py:402
↓ 1 callers
Method
_mst_decode
Decodes the head and head tag predictions using the Edmonds' Algorithm for finding minimum spanning trees on directed graphs. Nodes i
src/allen_parser.py:458
↓ 1 callers
Method
_run_mst_decoding
(batch_energy: torch.Tensor, lengths: torch.Tensor)
src/allen_parser.py:527
↓ 1 callers
Method
_setattr_
(obj, key, val)
src/glo.py:45
↓ 1 callers
Method
_test_exception
(self, gold, system)
src/utils/evaluation_script/conll17_ud_eval.py:526
↓ 1 callers
Function
align_words
(gold_words, system_words)
src/utils/evaluation_script/conll17_ud_eval.py:356
↓ 1 callers
Function
compute_lcs
(gold_words, system_words, gi, si, gs, ss)
src/utils/evaluation_script/conll17_ud_eval.py:346
↓ 1 callers
Method
compute_y_t_batch
this is a variational bound. q(y|t) namely the decoder. This returns a log-probability, total_error_number, and t
src/baselines.py:217
↓ 1 callers
Method
compute_y_t_batch
this is a variational bound. q(y|t) namely the decoder. This returns a log-probability, total_error_number, and t
src/baselines.py:385
↓ 1 callers
Method
decode
(self, output_dict: Dict[str, torch.Tensor])
src/allen_parser.py:306
↓ 1 callers
Function
evaluate_wrapper
(args)
src/utils/evaluation_script/conll17_ud_eval.py:455
↓ 1 callers
Method
file_reader
(self, path)
src/conllu_handler.py:451
↓ 1 callers
Method
fill_parents
(self)
src/utils/evaluation_script/conll17_ud_eval.py:256
↓ 1 callers
Function
find_multiword_span
(gold_words, system_words, gi, si)
src/utils/evaluation_script/conll17_ud_eval.py:319
↓ 1 callers
Function
fine_parse
(args)
src/main.py:126
↓ 1 callers
Method
forward_sent_batch
:param sent: the input sentence in string :param elmo_embeds: the elmo look up table. :param index: the index of the sentenc
src/discrete_tag.py:55
↓ 1 callers
Method
forward_sent_batch
(self, sent, embeds)
src/gaussian_tag.py:58
↓ 1 callers
Method
get_dict
(self, train_data)
src/conllu_handler.py:277
↓ 1 callers
Method
get_dict
(self, train_data)
src/conllu_handler.py:910
↓ 1 callers
Method
get_sample_from_param_batch
(self, mean, cov, sample_size)
src/gaussian_tag.py:67
↓ 1 callers
Method
get_tree
(self, train_data)
src/conllu_handler.py:241
↓ 1 callers
Method
get_tree
(self, train_data)
src/conllu_handler.py:874
↓ 1 callers
Function
iden_parse
(args)
src/main.py:295
next →
1–100 of 199, ranked by callers