Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/ShenDezhou/CAIL
/ functions
Functions
6,528 in github.com/ShenDezhou/CAIL
⨍
Functions
6,528
◇
Types & classes
1,183
↳
Endpoints
4
↓ 727 callers
Method
size
(self)
CAIL2020/sfzywg/rouge/dict.py:31
↓ 426 callers
Method
load
(module, prefix='')
CAIL2020/ydlj/baseline/transformers/modeling_utils.py:453
↓ 362 callers
Method
from_pretrained
r""" Instantiates one of the base model classes of the library from a pre-trained model configuration. The model class to instantiate
CAIL2020/ydlj/baseline/transformers/modeling_auto.py:71
↓ 325 callers
Method
split
(self, content)
CAIL2020/zwfc/data.py:247
↓ 201 callers
Method
sample
labels: [b1, b2] Return true_log_probs: [b1, b2] samp_log_probs: [n_sample] neg_samples: [n_s
CAIL2020/ydlj/baseline/transformers/modeling_transfo_xl_utilities.py:280
↓ 136 callers
Function
ids_tensor
Creates a random int32 tensor of the shape within the vocab size.
CAIL2020/ydlj/baseline/transformers/tests/modeling_common_test.py:782
↓ 121 callers
Method
update
(self, val, n=1)
CAIL2020/cocr/torchocr/metrics/DetMetric.py:19
↓ 109 callers
Function
shape_list
Deal with dynamic shape in tensorflow cleanly.
CAIL2020/ydlj/baseline/transformers/modeling_tf_utils.py:507
↓ 82 callers
Method
step
Performs a single optimization step. Arguments: closure (callable, optional): A closure that reevaluates the model
CAIL2020/sfksz/model/lamb.py:60
↓ 75 callers
Function
get_initializer
Creates a `tf.initializers.truncated_normal` with the given range. Args: initializer_range: float, initializer range for stddev. Retur
CAIL2020/ydlj/baseline/transformers/modeling_tf_utils.py:513
↓ 70 callers
Method
step
Performs a single optimization step. Arguments: closure (callable, optional): A closure that reevaluates the model
CAIL2020/ydlj/baseline/transformers/optimization.py:110
↓ 64 callers
Method
read
(self, filenames, encoding=None)
CAIL2020/sfks/config_parser/parser.py:12
↓ 63 callers
Function
get_linear_schedule_with_warmup
Create a schedule with a learning rate that decreases linearly after linearly increasing during a warmup period.
CAIL2020/ydlj/baseline/transformers/optimization.py:45
↓ 60 callers
Method
add
(self, label, idx=None)
CAIL2020/sfzywg/rouge/dict.py:80
↓ 59 callers
Method
encode
Converts a string in a sequence of ids (integer), using the tokenizer and vocabulary. Same as doing ``self.convert_tokens_to_ids(sel
CAIL2020/ydlj/baseline/transformers/tokenization_utils.py:732
↓ 56 callers
Method
tokenize
Basic Tokenization of a piece of text. Split on "white spaces" only, for sub-word tokenization, see WordPieceTokenizer. Args:
CAIL2020/ydlj/baseline/transformers/tokenization_bert.py:292
↓ 55 callers
Method
transform
(self, word)
CAIL2020/sfks/formatter/qa/Comatch.py:19
↓ 48 callers
Method
init_weights
Initialize and prunes weights if needed.
CAIL2020/ydlj/baseline/transformers/modeling_utils.py:209
↓ 47 callers
Method
predict
(self, model, dataloader, exam, feats, prediction_file, need_sp_logit_file=False)
CAIL2020/ydljz/train.py:179
↓ 44 callers
Method
size
(self)
CAIL2020/sfzyzc/rouge/dict.py:31
↓ 43 callers
Function
get_constant_schedule
Create a schedule with a constant learning rate.
CAIL2020/ydlj/baseline/transformers/optimization.py:27
↓ 39 callers
Method
run
(self)
CAIL2020/ydlj/baseline/transformers/commands/user.py:46
↓ 36 callers
Method
decode
Converts a sequence of ids (integer) in a string, using the tokenizer and vocabulary with options to remove special tokens and clean
CAIL2020/ydlj/baseline/transformers/tokenization_utils.py:1156
↓ 36 callers
Function
is_torch_available
()
CAIL2020/ydlj/baseline/transformers/file_utils.py:78
↓ 35 callers
Method
train
Train model on train set and evaluate on train and valid set. Returns: state dict of the best model with highest valid f1 score
CAIL2020/ydljz/train.py:246
↓ 33 callers
Method
close
(self)
CAIL2020/ydlj/baseline/transformers/hf_api.py:180
↓ 32 callers
Method
convert_tokens_to_ids
Converts a single token, or a sequence of tokens, (str/unicode) in a single integer id (resp. a sequence of ids), using the vocabulary.
CAIL2020/ydlj/baseline/transformers/tokenization_utils.py:706
↓ 31 callers
Function
is_tf_available
()
CAIL2020/ydlj/baseline/transformers/file_utils.py:81
↓ 30 callers
Method
encoder
(self, sub)
CAIL2020/zwfc/data.py:203
↓ 26 callers
Method
__init__
(self, config)
CAIL2020/ydlj/baseline/transformers/modeling_bert.py:345
↓ 25 callers
Method
process
调用执行函数 :param _image: 待处理图像 :return: 执行后的Image对象
CAIL2020/cocr/torchocr/utils/CreateRecAug.py:82
↓ 24 callers
Method
split
(self, content)
CAIL2020/jesbl/data.py:249
↓ 23 callers
Method
setparam
(self, lower=0, upper=1)
CAIL2020/cocr/torchocr/utils/CreateRecAug.py:262
↓ 21 callers
Method
__init__
(self, config, **kwargs)
CAIL2020/ydlj/baseline/transformers/modeling_tf_bert.py:332
↓ 21 callers
Method
_read_tsv
Reads a tab separated value file.
CAIL2020/ydlj/baseline/transformers/data/processors/utils.py:118
↓ 20 callers
Method
run_common_tests
(self)
CAIL2020/ydlj/baseline/transformers/tests/modeling_common_test.py:773
↓ 19 callers
Method
flatten
(self, ll)
CAIL2020/ydljz(hong)/torch_server.py:107
↓ 19 callers
Method
split
(self, content)
CAIL2020/lawsplit/torch_server.py:73
↓ 18 callers
Method
from_pretrained
r""" Instantiates one of the base model classes of the library from a pre-trained model configuration. The model class to instantiate
CAIL2020/ydlj/baseline/transformers/modeling_tf_auto.py:65
↓ 18 callers
Function
get_labels_from_file
Get labels on the last column from file. Args: filename: file name Returns: List[str]: label list
CAIL2020/znwd/evaluate.py:33
↓ 17 callers
Function
calculate_accuracy_f1
Calculate accuracy and f1 score. Args: golds: answers predicts: predictions given by model Returns: accuracy, f1 sco
CAIL2020/znwd/evaluate.py:16
↓ 17 callers
Method
encode
convert text-label into text-index. input: text: text labels of each image. [batch_size] output: text: concate
CAIL2020/cocr/torchocr/utils/label_convert.py:20
↓ 17 callers
Function
evaluate
Evaluate model on data loader in device. Args: model: model to be evaluate data_loader: torch.utils.data.DataLoader devic
CAIL2020/znwd/evaluate.py:65
↓ 17 callers
Method
get_tokenizer
(self, **kwargs)
CAIL2020/ydlj/baseline/transformers/tests/tokenization_tests_commons.py:52
↓ 17 callers
Method
prepare_config_and_inputs_for_common
(self)
CAIL2020/ydlj/baseline/transformers/tests/modeling_common_test.py:720
↓ 17 callers
Function
prune_linear_layer
Prune a linear layer (a model parameters) to keep only entries in index. Return the pruned layer as a new layer with requires_grad=True.
CAIL2020/ydlj/baseline/transformers/modeling_utils.py:809
↓ 16 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
CAIL2020/ydlj/baseline/transformers/tokenization_xlm.py:763
↓ 16 callers
Method
empty
(self)
CAIL2020/ydljz/data_iterator_pack.py:30
↓ 15 callers
Method
flatten
(self, ll)
CAIL2020/zwfc/train.py:117
↓ 14 callers
Method
decode
Find the most likely tag sequence using Viterbi algorithm. Args: emissions (`~torch.Tensor`): Emission score tensor of size
CAIL2020/zwfc/model.py:676
↓ 14 callers
Function
get_pil_image
将图像统一转换为PIL格式 :param image: 图像 :return: Image格式的图像
CAIL2020/cocr/torchocr/utils/CreateRecAug.py:21
↓ 13 callers
Method
__init__
(self, num_tags, batch_first)
CAIL2020/zwfc/model.py:603
↓ 13 callers
Function
build_vocab
Build vocab.txt for SMP-CAIL2020-Argmine.
CAIL2020/znwd/vocab.py:89
↓ 13 callers
Method
encode_plus
Returns a dictionary containing the encoded sequence or sequence pair and additional informations: the mask for sequence classificati
CAIL2020/ydlj/baseline/transformers/tokenization_utils.py:788
↓ 12 callers
Method
__init__
(self, num_tags, batch_first)
CAIL2021/stxq/model.py:603
↓ 12 callers
Method
__init__
(self, num_tags, batch_first)
CAIL2021/slsb/model.py:602
↓ 12 callers
Method
__init__
(self, num_tags, batch_first)
CAIL2020/jesbl/model.py:603
↓ 12 callers
Function
gen_time_str
(t)
CAIL2020/sfksz/tools/eval_tool.py:12
↓ 12 callers
Function
gen_time_str
(t)
CAIL2020/sfkst/eval_tool.py:16
↓ 12 callers
Function
gen_time_str
(t)
CAIL2020/sfksu/eval_tool.py:16
↓ 12 callers
Function
gen_time_str
(t)
CAIL2020/sfks/tools/eval_tool.py:12
↓ 12 callers
Method
lookup
(self, key, default=None)
CAIL2020/sfzywg/rouge/dict.py:56
↓ 12 callers
Method
lookup
(self, key, default=None)
CAIL2020/sfzyzc/rouge/dict.py:56
↓ 11 callers
Method
__init__
(self, config, **kwargs)
CAIL2020/ydlj/baseline/transformers/modeling_tf_distilbert.py:263
↓ 11 callers
Method
add
(self, label, idx=None)
CAIL2020/sfzyzc/rouge/dict.py:80
↓ 11 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
CAIL2020/ydlj/baseline/transformers/file_utils.py:170
↓ 11 callers
Method
parse
(self, sent)
CAIL2020/sfks/formatter/qa/Comatch.py:68
↓ 10 callers
Method
__init__
(self, config, **kwargs)
CAIL2020/ydlj/baseline/transformers/modeling_tf_albert.py:314
↓ 10 callers
Method
from_json_file
Constructs a `Config` from a json file of parameters.
CAIL2020/ydlj/baseline/transformers/configuration_utils.py:191
↓ 10 callers
Method
prepare_config_and_inputs
(self)
CAIL2020/ydlj/baseline/transformers/tests/modeling_bert_test.py:92
↓ 10 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_
CAIL2020/ydlj/baseline/transformers/modeling_utils.py:236
↓ 10 callers
Method
tokenize
Cut words for a sentence. Args: sentence: sentence Returns: words list
CAIL2020/ydljz/data.py:73
↓ 10 callers
Method
tokenize
Cut words for a sentence. Args: sentence: sentence Returns: words list
CAIL2020/ydljzs/data.py:73
↓ 10 callers
Method
tokenize
Cut words for a sentence. Args: sentence: sentence Returns: words list
CAIL2020/ydljztpus/data.py:73
↓ 10 callers
Method
tokenize
Cut words for a sentence. Args: sentence: sentence Returns: words list
CAIL2020/sfksy/data.py:71
↓ 10 callers
Method
tokenize
Cut words for a sentence. Args: sentence: sentence Returns: words list
CAIL2020/ydljzt/data.py:73
↓ 10 callers
Method
tokenize
Cut words for a sentence. Args: sentence: sentence Returns: words list
CAIL2020/ydljtpu/data.py:72
↓ 10 callers
Method
tokenize
Cut words for a sentence. Args: sentence: sentence Returns: words list
CAIL2020/ydljztpu/data.py:73
↓ 10 callers
Method
tokenize
Cut words for a sentence. Args: sentence: sentence Returns: words list
CAIL2020/ydljx/data.py:72
↓ 10 callers
Method
tokenize
Cut words for a sentence. Args: sentence: sentence Returns: words list
CAIL2020/ydljz(hong)tpu/data.py:73
↓ 10 callers
Method
tokenize
Cut words for a sentence. Args: sentence: sentence Returns: words list
CAIL2020/ydljz(hong)/data.py:74
↓ 9 callers
Method
__init__
(self, config)
CAIL2020/ydlj/baseline/transformers/modeling_distilbert.py:201
↓ 9 callers
Method
__init__
(self, config)
CAIL2020/ydlj/baseline/transformers/modeling_xlnet.py:425
↓ 9 callers
Method
__init__
(self, config, **kwargs)
CAIL2020/ydlj/baseline/transformers/modeling_tf_xlnet.py:312
↓ 9 callers
Method
__init__
(self, config)
CAIL2020/ydlj/baseline/transformers/modeling_albert.py:253
↓ 9 callers
Function
_resnet
(arch, block, layers, pretrained, progress, **kwargs)
CAIL2020/ydljz/resnet2d.py:225
↓ 9 callers
Function
_resnet
(arch, block, layers, pretrained, progress, **kwargs)
CAIL2020/ydljz/resnet.py:224
↓ 9 callers
Function
_resnet
(arch, block, layers, pretrained, progress, **kwargs)
CAIL2020/ydljzs/resnet2d.py:225
↓ 9 callers
Function
_resnet
(arch, block, layers, pretrained, progress, **kwargs)
CAIL2020/ydljzs/resnet.py:224
↓ 9 callers
Function
_resnet
(arch, block, layers, pretrained, progress, **kwargs)
CAIL2020/ydljztpus/resnet2d.py:225
↓ 9 callers
Function
_resnet
(arch, block, layers, pretrained, progress, **kwargs)
CAIL2020/ydljztpus/resnet.py:224
↓ 9 callers
Function
_resnet
(arch, block, layers, pretrained, progress, **kwargs)
CAIL2020/ydljzt/resnet2d.py:225
↓ 9 callers
Function
_resnet
(arch, block, layers, pretrained, progress, **kwargs)
CAIL2020/ydljzt/resnet.py:224
↓ 9 callers
Function
_resnet
(arch, block, layers, pretrained, progress, **kwargs)
CAIL2020/ydljtpu/resnet.py:223
↓ 9 callers
Function
_resnet
(arch, block, layers, pretrained, progress, **kwargs)
CAIL2020/ydljztpu/resnet2d.py:225
↓ 9 callers
Function
_resnet
(arch, block, layers, pretrained, progress, **kwargs)
CAIL2020/ydljztpu/resnet.py:224
↓ 9 callers
Function
_resnet
(arch, block, layers, pretrained, progress, **kwargs)
CAIL2020/ydljx/resnet.py:223
↓ 9 callers
Function
_resnet
(arch, block, layers, pretrained, progress, **kwargs)
CAIL2020/sfksz/model/qa/resnet.py:224
↓ 9 callers
Function
_resnet
(arch, block, layers, pretrained, progress, **kwargs)
CAIL2020/ydljz(hong)tpu/resnet2d.py:225
↓ 9 callers
Function
_resnet
(arch, block, layers, pretrained, progress, **kwargs)
CAIL2020/ydljz(hong)tpu/resnet.py:224
next →
1–100 of 6,528, ranked by callers