Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/ChineseGLUE/ChineseGLUE
/ functions
Functions
3,165 in github.com/ChineseGLUE/ChineseGLUE
⨍
Functions
3,165
◇
Types & classes
518
↓ 3 callers
Function
make_precision_recall_eval
(scores, na_probs, num_true_pos, qid_to_has_ans, out_image=None, title=None)
baselines/models/xlnet/squad_utils.py:143
↓ 3 callers
Method
post_attention
Post-attention processing.
baselines/models_pytorch/classifier_pytorch/transformers/modeling_xlnet.py:299
↓ 3 callers
Method
read_iteration_counts
(self)
baselines/models/xlnet/tpu_estimator.py:382
↓ 3 callers
Method
record
Records the host_call structure.
baselines/models/xlnet/tpu_estimator.py:1694
↓ 3 callers
Function
reshape_to_matrix
Reshapes a >= rank 2 tensor to a rank 2 tensor (i.e., a matrix).
baselines/models/roberta/modeling.py:932
↓ 3 callers
Function
reshape_to_matrix
Reshapes a >= rank 2 tensor to a rank 2 tensor (i.e., a matrix).
baselines/models/albert/modeling.py:1018
↓ 3 callers
Function
reshape_to_matrix
Reshapes a >= rank 2 tensor to a rank 2 tensor (i.e., a matrix).
baselines/models/roberta_wwm_ext/modeling.py:932
↓ 3 callers
Function
reshape_to_matrix
Reshapes a >= rank 2 tensor to a rank 2 tensor (i.e., a matrix).
baselines/models/ernie/modeling.py:932
↓ 3 callers
Function
reshape_to_matrix
Reshapes a >= rank 2 tensor to a rank 2 tensor (i.e., a matrix).
baselines/models/bert_wwm_ext/modeling.py:932
↓ 3 callers
Function
reshape_to_matrix
Reshapes a >= rank 2 tensor to a rank 2 tensor (i.e., a matrix).
baselines/models/roberta_wwm_large_ext/modeling.py:932
↓ 3 callers
Function
reshape_to_matrix
Reshapes a >= rank 2 tensor to a rank 2 tensor (i.e., a matrix).
baselines/models/bert/modeling.py:932
↓ 3 callers
Method
save_pretrained
Save a model and its configuration file to a directory, so that it can be re-loaded using the `:func:`~transformers.PreTrainedModel.from_
baselines/models_pytorch/classifier_pytorch/transformers/modeling_utils.py:206
↓ 3 callers
Method
split_heads
(self, x, k=False)
baselines/models_pytorch/classifier_pytorch/transformers/modeling_gpt2.py:172
↓ 3 callers
Method
split_heads
(self, x, k=False)
baselines/models_pytorch/classifier_pytorch/transformers/modeling_openai.py:196
↓ 3 callers
Method
split_into_heads
(self, x, batch_size)
baselines/models_pytorch/classifier_pytorch/transformers/modeling_ctrl.py:98
↓ 3 callers
Method
start
(self)
baselines/models_pytorch/mrc_pytorch/tools/langconv.py:207
↓ 3 callers
Method
tie_weights
Make sure we are sharing the input and output embeddings. Export to TorchScript can't handle parameter sharing so we are cloning them
baselines/models_pytorch/classifier_pytorch/transformers/modeling_ctrl.py:454
↓ 3 callers
Method
tokenize
Tokenizes a piece of text into its word pieces. This uses a greedy longest-match-first algorithm to perform tokenization using the given voca
baselines/models/roberta_wwm_ext/tokenization.py:308
↓ 3 callers
Method
tokenize
Tokenizes a piece of text into its word pieces. This uses a greedy longest-match-first algorithm to perform tokenization using the given voca
baselines/models/ernie/tokenization.py:308
↓ 3 callers
Method
tokenize
Tokenizes a piece of text into its word pieces. This uses a greedy longest-match-first algorithm to perform tokenization using the given voca
baselines/models/bert_wwm_ext/tokenization.py:308
↓ 3 callers
Method
tokenize
Tokenizes a piece of text into its word pieces. This uses a greedy longest-match-first algorithm to perform tokenization using the given voca
baselines/models/roberta_wwm_large_ext/tokenization.py:308
↓ 3 callers
Method
tokenize
Tokenizes a piece of text into its word pieces. This uses a greedy longest-match-first algorithm to perform tokenization using the given voca
baselines/models/bert/tokenization.py:308
↓ 3 callers
Method
transpose_for_scores
(self, x)
baselines/models_pytorch/classifier_pytorch/transformers/modeling_bert.py:196
↓ 3 callers
Method
transpose_for_scores
(self, x)
baselines/models_pytorch/mrc_pytorch/pytorch_modeling.py:357
↓ 3 callers
Function
whitespace_tokenize
Runs basic whitespace cleaning and splitting on a piece of text.
baselines/models_pytorch/classifier_pytorch/transformers/tokenization_bert.py:100
↓ 3 callers
Function
whitespace_tokenize
Runs basic whitespace cleaning and splitting on a peice of text.
baselines/models_pytorch/mrc_pytorch/tools/offical_tokenization.py:57
↓ 3 callers
Function
whitespace_tokenize
Runs basic whitespace cleaning and splitting on a piece of text.
baselines/models/roberta/tokenization.py:154
↓ 3 callers
Function
whitespace_tokenize
Runs basic whitespace cleaning and splitting on a piece of text.
baselines/models/albert/tokenization.py:154
↓ 3 callers
Function
whitespace_tokenize
Runs basic whitespace cleaning and splitting on a piece of text.
baselines/models/roberta_wwm_ext/tokenization.py:152
↓ 3 callers
Function
whitespace_tokenize
Runs basic whitespace cleaning and splitting on a piece of text.
baselines/models/ernie/tokenization.py:152
↓ 3 callers
Function
whitespace_tokenize
Runs basic whitespace cleaning and splitting on a piece of text.
baselines/models/bert_wwm_ext/tokenization.py:152
↓ 3 callers
Function
whitespace_tokenize
Runs basic whitespace cleaning and splitting on a piece of text.
baselines/models/roberta_wwm_large_ext/tokenization.py:152
↓ 3 callers
Function
whitespace_tokenize
Runs basic whitespace cleaning and splitting on a piece of text.
baselines/models/bert/tokenization.py:152
↓ 2 callers
Method
_clean
(self)
baselines/models_pytorch/mrc_pytorch/tools/langconv.py:200
↓ 2 callers
Function
_compute_softmax
Compute softmax probability over raw logits.
baselines/models_pytorch/mrc_pytorch/preprocess/cmrc2018_output.py:451
↓ 2 callers
Function
_compute_softmax
Compute softmax probability over raw logits.
baselines/models_pytorch/mrc_pytorch/preprocess/DRCD_output.py:449
↓ 2 callers
Method
_convert_id_to_token
(self, index)
baselines/models_pytorch/classifier_pytorch/transformers/tokenization_utils.py:980
↓ 2 callers
Method
_convert_token_to_id
(self, token)
baselines/models_pytorch/classifier_pytorch/transformers/tokenization_utils.py:688
↓ 2 callers
Method
_convert_token_to_id_with_added_voc
(self, token)
baselines/models_pytorch/classifier_pytorch/transformers/tokenization_utils.py:680
↓ 2 callers
Method
_create_examples
Creates examples for the training and dev sets.
baselines/models_pytorch/classifier_pytorch/processors/glue.py:169
↓ 2 callers
Method
_create_examples
Creates examples for the training and dev sets.
baselines/models_pytorch/classifier_pytorch/processors/glue.py:202
↓ 2 callers
Method
_create_examples
Creates examples for the training and dev sets.
baselines/models_pytorch/classifier_pytorch/processors/glue.py:364
↓ 2 callers
Method
_create_examples
Creates examples for the training and dev sets.
baselines/models_pytorch/classifier_pytorch/processors/glue.py:473
↓ 2 callers
Method
_create_examples
Creates examples for the training and dev sets.
baselines/models_pytorch/classifier_pytorch/processors/glue.py:504
↓ 2 callers
Method
_create_examples
Creates examples for the training and dev sets.
baselines/models_pytorch/classifier_pytorch/processors/glue.py:572
↓ 2 callers
Method
_create_examples
Creates examples for the training and dev sets.
baselines/models_pytorch/classifier_pytorch/processors/glue.py:604
↓ 2 callers
Method
_create_examples
Creates examples for the training and dev sets.
baselines/models_pytorch/classifier_pytorch/processors/glue.py:636
↓ 2 callers
Method
_create_examples
Creates examples for the training and dev sets.
baselines/models/xlnet/run_classifier_thucnews.py:617
↓ 2 callers
Method
_create_examples
(self, data_dir)
baselines/models/xlnet/run_classifier_thucnews.py:641
↓ 2 callers
Method
_create_examples
Creates examples for the training and dev sets.
baselines/models/xlnet/run_classifier.py:595
↓ 2 callers
Method
_create_examples
(self, data_dir)
baselines/models/xlnet/run_classifier.py:619
↓ 2 callers
Function
_get_best_indexes
Get the n-best logits from a list.
baselines/models_pytorch/mrc_pytorch/preprocess/cmrc2018_output.py:439
↓ 2 callers
Function
_get_best_indexes
Get the n-best logits from a list.
baselines/models_pytorch/mrc_pytorch/preprocess/DRCD_output.py:437
↓ 2 callers
Function
_get_best_indexes
Get the n-best logits from a list.
baselines/models/roberta_wwm_ext/run_squad.py:1023
↓ 2 callers
Function
_get_best_indexes
Get the n-best logits from a list.
baselines/models/ernie/run_squad.py:1023
↓ 2 callers
Function
_get_best_indexes
Get the n-best logits from a list.
baselines/models/bert_wwm_ext/run_squad.py:1023
↓ 2 callers
Function
_get_best_indexes
Get the n-best logits from a list.
baselines/models/roberta_wwm_large_ext/run_squad.py:1023
↓ 2 callers
Function
_get_best_indexes
Get the n-best logits from a list.
baselines/models/bert/run_squad.py:1023
↓ 2 callers
Function
_get_spm_basename
()
baselines/models/xlnet/run_cmrc_drcd.py:1096
↓ 2 callers
Function
_is_start_piece
(piece)
baselines/models/xlnet/data_utils.py:322
↓ 2 callers
Function
_local_perm
Sample a permutation of the factorization order, and create an attention mask accordingly. Args: inputs: int64 Tensor in shape [seq_len],
baselines/models/xlnet/data_utils.py:579
↓ 2 callers
Method
_next_iterations
(self, global_step, last_step)
baselines/models/xlnet/tpu_estimator.py:612
↓ 2 callers
Function
_sample_mask
Sample `goal_num_predict` tokens for partial prediction. About `mask_beta` tokens are chosen in a context of `mask_alpha` tokens.
baselines/models/xlnet/data_utils.py:331
↓ 2 callers
Function
_strip_spaces
(text)
baselines/models_pytorch/mrc_pytorch/preprocess/cmrc2018_output.py:373
↓ 2 callers
Function
_strip_spaces
(text)
baselines/models_pytorch/mrc_pytorch/preprocess/DRCD_output.py:371
↓ 2 callers
Function
_strip_spaces
(text)
baselines/models/roberta_wwm_ext/run_squad.py:955
↓ 2 callers
Function
_strip_spaces
(text)
baselines/models/ernie/run_squad.py:955
↓ 2 callers
Function
_strip_spaces
(text)
baselines/models/bert_wwm_ext/run_squad.py:955
↓ 2 callers
Function
_strip_spaces
(text)
baselines/models/roberta_wwm_large_ext/run_squad.py:955
↓ 2 callers
Function
_strip_spaces
(text)
baselines/models/bert/run_squad.py:955
↓ 2 callers
Method
_tie_or_clone_data
Tie or clone module weights depending of weither we are using TorchScript or not
baselines/models_pytorch/classifier_pytorch/transformers/modeling_utils.py:136
↓ 2 callers
Method
_tokenize
Converts a string in a sequence of tokens (string), using the tokenizer. Split in words for word-based vocabulary or sub-words for sub-wo
baselines/models_pytorch/classifier_pytorch/transformers/tokenization_utils.py:652
↓ 2 callers
Function
_tokenize_chinese_chars
Adds whitespace around any CJK character.
baselines/models_pytorch/mrc_pytorch/preprocess/DRCD_preprocess.py:132
↓ 2 callers
Function
_truncate_seq_pair
Truncates a sequence pair in place to the maximum length.
baselines/models/roberta/run_classifier.py:928
↓ 2 callers
Function
_truncate_seq_pair
Truncates a sequence pair in place to the maximum length.
baselines/models/albert/run_classifier.py:921
↓ 2 callers
Function
_truncate_seq_pair
Truncates a sequence pair in place to the maximum length.
baselines/models/roberta_wwm_ext/run_classifier.py:995
↓ 2 callers
Function
_truncate_seq_pair
Truncates a sequence pair in place to the maximum length.
baselines/models/ernie/run_classifier.py:1034
↓ 2 callers
Function
_truncate_seq_pair
Truncates a sequence pair in place to the maximum length.
baselines/models/bert_wwm_ext/run_classifier.py:1045
↓ 2 callers
Function
_truncate_seq_pair
Truncates a sequence pair in place to the maximum length.
baselines/models/roberta_wwm_large_ext/run_classifier.py:1039
↓ 2 callers
Function
_truncate_seq_pair
Truncates a sequence pair in place to the maximum length.
baselines/models/bert/run_classifier.py:1038
↓ 2 callers
Function
acc_and_f1
(preds, labels)
baselines/models_pytorch/classifier_pytorch/metrics/glue_compute_metrics.py:37
↓ 2 callers
Method
add_symbol
(self, sym)
baselines/models_pytorch/classifier_pytorch/transformers/tokenization_transfo_xl.py:213
↓ 2 callers
Method
add_tokens
Add a list of new tokens to the tokenizer class. If the new tokens are not in the vocabulary, they are added to it with indices start
baselines/models_pytorch/classifier_pytorch/transformers/tokenization_utils.py:488
↓ 2 callers
Method
apply_gradients
See base class.
baselines/models/roberta_wwm_ext/optimization.py:108
↓ 2 callers
Method
apply_gradients
See base class.
baselines/models/ernie/optimization.py:108
↓ 2 callers
Method
apply_gradients
See base class.
baselines/models/bert_wwm_ext/optimization.py:108
↓ 2 callers
Method
apply_gradients
See base class.
baselines/models/roberta_wwm_large_ext/optimization.py:108
↓ 2 callers
Method
apply_gradients
See base class.
baselines/models/bert/optimization.py:108
↓ 2 callers
Function
apply_no_ans_threshold
(scores, na_probs, qid_to_has_ans, na_prob_thresh)
baselines/models/xlnet/squad_utils.py:102
↓ 2 callers
Function
attention_layer
Performs multi-headed attention from `from_tensor` to `to_tensor`. This is an implementation of multi-headed attention based on "Attention is all
baselines/models/albert/modeling.py:637
↓ 2 callers
Function
batchify
(data, bsz_per_host, sent_ids=None)
baselines/models/xlnet/data_utils.py:242
↓ 2 callers
Method
bpe
(self, token)
baselines/models_pytorch/classifier_pytorch/transformers/tokenization_openai.py:115
↓ 2 callers
Method
build_inputs_with_special_tokens
Build model inputs from a sequence or a pair of sequence for sequence classification tasks by concatenating and adding special tokens
baselines/models_pytorch/classifier_pytorch/transformers/tokenization_utils.py:928
↓ 2 callers
Method
build_vocab
(self)
baselines/models_pytorch/classifier_pytorch/transformers/tokenization_transfo_xl.py:155
↓ 2 callers
Function
cached_path
Given something that might be a URL (or might be a local path), determine which. If it's a URL, download the file and cache it, and retur
baselines/models_pytorch/mrc_pytorch/tools/file_utils.py:73
↓ 2 callers
Function
calc_em_score
(answers, prediction)
baselines/models_pytorch/mrc_pytorch/preprocess/cmrc2018_evaluate.py:175
↓ 2 callers
Function
calc_f1_score
(answers, prediction)
baselines/models_pytorch/mrc_pytorch/preprocess/cmrc2018_evaluate.py:159
↓ 2 callers
Function
calculate_metrics
(correct, guessed, total)
baselines/models/roberta/conlleval.py:152
↓ 2 callers
Function
calculate_metrics
(correct, guessed, total)
baselines/models/roberta_wwm_ext/conlleval.py:152
↓ 2 callers
Function
calculate_metrics
(correct, guessed, total)
baselines/models/ernie/conlleval.py:152
← previous
next →
401–500 of 3,165, ranked by callers