MCPcopy Create free account

hub / github.com/espnet/espnet / functions

Functions9,880 in github.com/espnet/espnet

↓ 2,923 callersMethodappend
Adds a new message to the chat buffer. Removes the oldest prompt-response pair if the buffer exceeds the maximum allowed size.
espnet2/sds/utils/chat.py:39
↓ 2,487 callersMethodformat
(self)
egs2/cmu_kids/asr1/local/sph2wav.py:97
↓ 1,523 callersMethodsplit
(self, threshold=30)
egs2/pjs/svs1/local/prep_segments.py:32
↓ 1,463 callersMethodsize
(self)
egs2/ml_superb/asr1/local/linguistic_tree.py:75
↓ 783 callersMethodto
(self, device)
test/espnet3/components/data/test_collect_stats.py:151
↓ 555 callersMethodget
(key, default=None)
test/espnet2/speechlm/model/conftest.py:79
↓ 443 callersMethodupdate
(self, cfg: dict)
espnet2/asr/encoder/beats_encoder.py:100
↓ 412 callersMethoditems
Return keys and values of file key.
espnet2/legacy/utils/io_utils.py:78
↓ 376 callersMethodopen
(self)
egs2/cmu_kids/asr1/local/sph2wav.py:70
↓ 345 callersMethodclose
(self)
espnet2/fileio/score_scp.py:206
↓ 306 callersMethodkeys
(self)
egs2/kiritan/svs1/local/prep_segments_from_xml.py:115
↓ 273 callersMethodsplit
(self, threshold=30)
egs2/TEMPLATE/asr1/pyscripts/utils/prep_segments.py:37
↓ 226 callersMethodeval
(self)
test/espnet2/speechlm/trainer/conftest.py:39
↓ 215 callersMethodget_class
(self, name: Optional[str])
espnet2/train/class_choices.py:64
↓ 195 callersMethodbackward
(self, loss)
test/espnet2/speechlm/trainer/conftest.py:43
↓ 177 callersMethoddim
(self, layer_to_dim)
egs2/TEMPLATE/asr1/steps/libs/nnet3/xconfig/utils.py:261
↓ 156 callersMethodvalues
Return values of file key.
espnet2/legacy/utils/io_utils.py:73
↓ 149 callersMethodextend
Extend probabilities and states with more encoded chunks. Args: x (torch.Tensor): The extended encoder output feature
espnet2/legacy/nets/batch_beam_search_online.py:519
↓ 144 callersMethodupdate
(self, d)
test/espnet2/speechlm/trainer/conftest.py:82
↓ 127 callersMethodparameters
(self)
test/espnet2/speechlm/trainer/conftest.py:61
↓ 124 callersMethodmain
( cls, args: Optional[argparse.Namespace] = None, cmd: Optional[Sequence[str]] = None,
espnet2/tasks/abs_task.py:1260
↓ 120 callersMethodlog
(self, *args, **kwargs)
test/espnet2/cls/test_lightning_callbacks.py:16
↓ 117 callersMethodsplit
(self, threshold=30)
egs2/ofuton_p_utagoe_db/svs1/local/prep_segments.py:32
↓ 112 callersFunctionmake_pad_mask
Make mask tensor containing indices of padded part. Args: lengths (LongTensor or List): Batch of lengths (B,). xs (Tensor, option
espnet2/legacy/nets/pytorch_backend/nets_utils.py:65
↓ 112 callersMethodupdate
r"""Update margin and related trigonometric values during training.
espnet2/spk/loss/aamsoftmax_subcenter_intertopk.py:91
↓ 110 callersMethodsearch
Search new tokens for running hypotheses and encoded speech x. Args: running_hyps (List[Hypothesis]): Running hypotheses on beam
espnet2/legacy/nets/beam_search.py:316
↓ 90 callersMethodtrain
(self, mode=True)
test/espnet2/speechlm/trainer/conftest.py:35
↓ 89 callersMethodget_parser
(cls)
espnet2/tasks/abs_task.py:294
↓ 86 callersMethodoutput_size
(self)
espnet2/tts/feats_extract/dio.py:69
↓ 82 callersFunctionto_device
Change the device of object recursively
espnet2/torch_utils/device_funcs.py:8
↓ 79 callersMethodsplit
(self, threshold=30)
egs2/ameboshi/svs1/local/prep_segments.py:32
↓ 75 callersMethodargmax
argmax of frame activations Args: torch.Tensor hs_pad: 3d tensor (B, Tmax, eprojs) Returns: torch.Tensor: arg
espnet2/asr/ctc.py:206
↓ 75 callersMethodcopy
(self)
espnet2/enh/diffusion/sdes.py:156
↓ 75 callersMethodsoftmax
softmax of frame activations Args: Tensor hs_pad: 3d tensor (B, Tmax, eprojs) Returns: torch.Tensor: softmax
espnet2/asr/ctc.py:186
↓ 74 callersMethodkeys
(self)
espnet2/fileio/rttm.py:94
↓ 70 callersMethoditems
(self)
test/espnet2/speechlm/dataloader/test_dataset.py:40
↓ 68 callersMethodexpand
Expand input mel-spectrogram based on the predicted duration. Args: batch (Tensor): Input tensor (T, dim). predicted
espnet2/gan_svs/vits/length_regulator.py:53
↓ 68 callersFunctionget_commandline_args
Get command line arguments.
espnet2/legacy/utils/cli_utils.py:9
↓ 64 callersFunctioninstantiate
Instantiate registered module. registry: Dictionary mapping names to functions or target paths (e.g. {'model': 'models.SequenceModel'
espnet2/asr/state_spaces/utils.py:69
↓ 64 callersMethodstate_dict
(self)
espnet2/train/reporter.py:569
↓ 63 callersFunctionmake_non_pad_mask
Make mask tensor containing indices of non-padded part. Args: lengths (LongTensor or List): Batch of lengths (B,). xs (Tensor, op
espnet2/legacy/nets/pytorch_backend/nets_utils.py:265
↓ 60 callersFunctionforce_gatherable
Change object to gatherable in torch.nn.DataParallel recursively The difference from to_device() is changing to torch.Tensor if float or int
espnet2/torch_utils/device_funcs.py:48
↓ 58 callersMethodload_state_dict
(self, state_dict: dict)
espnet2/train/reporter.py:572
↓ 55 callersMethodnext
Close up this step and reset state for the next step
espnet2/train/reporter.py:135
↓ 53 callersFunctionrepeat
Repeat module N times. Args: N (int): Number of repeat time. fn (Callable): Function to generate module. layer_drop_rate
espnet2/legacy/nets/pytorch_backend/transformer/repeat.py:34
↓ 52 callersMethodadd
(self, start, end, label)
egs2/pjs/svs1/local/prep_segments.py:23
↓ 51 callersMethodbuild_model_from_file
Build model from the files. This method is used for inference or fine-tuning. Args: config_file: The yaml file saved whe
espnet2/tasks/abs_task.py:2452
↓ 47 callersMethodsplit
(self, threshold=30)
egs2/itako/svs1/local/prep_segments.py:32
↓ 45 callersMethodobserve
(self, key: str, epoch: int = None)
espnet2/train/reporter.py:304
↓ 45 callersFunctionset_all_random_seed
(seed: int)
espnet2/torch_utils/set_all_random_seed.py:7
↓ 45 callersFunctionto_double
(c)
espnet2/enh/layers/complex_utils.py:45
↓ 43 callersFunctionbuild_tokenizer
A helper function to instantiate Tokenizer
espnet2/text/build_tokenizer.py:17
↓ 42 callersFunctionget_default_kwargs
Get the default values of the input function. Examples: >>> def func(a, b=3): pass >>> get_default_kwargs(func) {'b': 3}
espnet2/utils/get_default_kwargs.py:8
↓ 42 callersMethoditems
Return iterator over (id, text) pairs.
espnet2/speechlm/dataloader/multimodal_loader/text_loader.py:183
↓ 41 callersMethodregister
(self, name, table)
test/espnet2/speechlm/dataloader/conftest.py:64
↓ 40 callersMethodinsert
(self, word)
egs2/powsm/s2t1/local/data_prep.py:191
↓ 39 callersMethodstep
(self)
test/espnet2/speechlm/trainer/conftest.py:46
↓ 38 callersMethodbuild_preprocess_fn
( cls, args: argparse.Namespace, train: bool )
espnet2/tasks/mt.py:285
↓ 38 callersMethodfrom_pretrained
Build Text2Text instance from the pretrained model. Args: model_tag (Optional[str]): Model tag of the pretrained models.
espnet2/bin/mt_inference.py:243
↓ 38 callersMethodids2tokens
(self, integers: Union[np.ndarray, Iterable[int]])
espnet2/text/token_id_converter.py:51
↓ 38 callersMethodlog_softmax
log_softmax of frame activations Args: Tensor hs_pad: 3d tensor (B, Tmax, eprojs) Returns: torch.Tensor: log
espnet2/asr/ctc.py:196
↓ 36 callersMethodlog_softmax
Computes the log softmax denominator of the input activation tensor and stores the result in denom. Args: acts: Activati
espnet2/asr/transducer/rnnt_multi_blank/utils/cuda_utils/gpu_rnnt.py:98
↓ 35 callersMethodadd
(self, start, end, label, midi=None)
egs2/TEMPLATE/asr1/pyscripts/utils/prep_segments.py:25
↓ 34 callersFunctionis_complex
(c)
espnet2/enh/layers/complex_utils.py:30
↓ 33 callersMethodbuild_streaming_iterator
Build DataLoader using iterable dataset
espnet2/tasks/abs_task.py:2399
↓ 33 callersFunctioninitialize
Initialize weights of a neural network module. Parameters are initialized using the given method or distribution. Custom initialization rout
espnet2/torch_utils/initialize.py:12
↓ 33 callersMethodsave
(self)
egs2/dsing/asr1/local/data_prep.py:80
↓ 32 callersMethodadd
(self, filename, arcname=None, recursive: bool = True)
espnet2/main_funcs/pack_funcs.py:58
↓ 32 callersMethodtokens2text
(self, tokens: Iterable[str])
espnet2/text/abs_tokenizer.py:11
↓ 31 callersMethodtext2tokens
(self, line: str)
espnet2/text/abs_tokenizer.py:7
↓ 30 callersMethodadd_pause
(self, labels, segment, segments, threshold)
egs2/TEMPLATE/asr1/pyscripts/utils/prep_segments.py:148
↓ 30 callersMethodbuild_collate_fn
(cls, args: argparse.Namespace, train: bool)
espnet2/tasks/mt.py:276
↓ 30 callersMethodregister
( self, stats: Dict[str, Optional[Union[Num, Dict[str, Num]]]], weight: Optional[Num]
espnet2/train/reporter.py:152
↓ 29 callersMethodadd_arguments
Reserved for future development of another Trainer
espnet2/train/trainer.py:135
↓ 28 callersMethodinference
Run inference. Args: text (Tensor): Input text index tensor (T_text,). feats (Tensor): Feature tensor (T_feats, aux_c
espnet2/gan_svs/vits/vits.py:930
↓ 28 callersMethodrun
Perform training. This method performs the main process of training.
espnet2/train/trainer.py:172
↓ 28 callersMethodselect_state
Get specified ID state from decoder hidden states. Args: states: Decoder hidden states. ((N, B, D_dec), (N, B, D_dec))
espnet2/asr/decoder/transducer_decoder.py:260
↓ 27 callersMethodtokens2ids
(self, tokens: Iterable[str])
espnet2/text/token_id_converter.py:56
↓ 27 callersFunctionwrite_yaml
Fixture to create a YAML file under tmp_path and return its path. Usage: path = write_yaml("filename.yaml", content_as_str)
test/espnet3/utils/test_config.py:95
↓ 26 callersMethodcomplex
(self, x)
espnet2/gan_svs/visinger2/visinger2_vocoder.py:860
↓ 26 callersFunctionlogp
Compute the sum of log probability from the activation tensor and its denominator. Args: denom: Tensor of shape [B, T, U] flattened.
espnet2/asr/transducer/rnnt_multi_blank/utils/cuda_utils/gpu_rnnt_kernel.py:40
↓ 25 callersMethodset_epoch
(self, epoch: int)
espnet2/train/reporter.py:298
↓ 25 callersFunctionto_device
Send tensor into the device of the module. Args: m (torch.nn.Module): Torch module. x (Tensor): Torch tensor. Returns:
espnet2/legacy/nets/pytorch_backend/nets_utils.py:12
↓ 24 callersMethodbatch_score
Score new token batch. Args: ys (torch.Tensor): torch.int64 prefix tokens (n_batch, ylen). states (List[Any]): Scorer
espnet2/asr/decoder/s4_decoder.py:138
↓ 24 callersMethoddecode
Run encoding. Args: x (Tensor): Input codes (T_code, N_stream). Returns: Tensor: Generated waveform (T_wav,)
espnet2/gan_codec/dac/dac.py:447
↓ 24 callersFunctionlayershift
(input_id, layer, stride=4160, shift=152000)
espnet2/sds/end_to_end/mini_omni/utils/snac_utils.py:29
↓ 24 callersFunctionstr_or_none
str_or_none. Examples: >>> import argparse >>> parser = argparse.ArgumentParser() >>> _ = parser.add_argument('--foo', ty
espnet2/utils/types.py:86
↓ 23 callersMethodconfigure_optimizers
Configure single-optimizer-path or named multi-path optimizers. This includes the paired scheduler configuration. Single-optimizer-p
espnet3/components/modeling/lightning_module.py:407
↓ 23 callersFunctioneinsum
(equation, *operands)
espnet2/enh/layers/complex_utils.py:87
↓ 23 callersMethodgather
(self, futures)
test/espnet3/parallel/test_inference_runner.py:287
↓ 23 callersFunctionload_config_with_defaults
Load an YAML config with recursive `_self_` merging via Hydra-style `defaults`. This function recursively loads and merges dependent YAML files s
espnet3/utils/config_utils.py:129
↓ 23 callersFunctionpad_list
Perform padding for the list of tensors. Args: xs (List): List of Tensors [(T_1, `*`), (T_2, `*`), ..., (T_B, `*`)]. pad_value (f
espnet2/legacy/nets/pytorch_backend/nets_utils.py:34
↓ 22 callersFunctionbuild_dataclass
Helper function to build dataclass from 'args'.
espnet2/utils/build_dataclass.py:5
↓ 22 callersMethodfrom_recordings
(cls, recordings)
test/espnet2/speechlm/dataloader/conftest.py:114
↓ 21 callersMethodencode
(self, speech, lengths)
espnet2/bin/diar_inference.py:401
↓ 21 callersMethodfrom_pretrained
Load pretrained model and adapt it for multimodal parallel processing. Args: pretrained_model_name_or_path: HF model path
espnet2/speechlm/model/speechlm/lm/parallel.py:48
↓ 21 callersMethodkeys
Return iterator over IDs.
espnet2/speechlm/dataloader/multimodal_loader/text_loader.py:175
↓ 21 callersMethodkeys
(self)
espnet2/train/dataset.py:61
↓ 21 callersMethodstep
Step one time step as a recurrent model. Intended to be used during validation. u: (B H) state: (B H N) Returns: out
espnet2/asr/state_spaces/s4.py:1789
↓ 21 callersFunctionsubsequent_mask
Create mask for subsequent steps (size, size). :param int size: size of mask :param str device: "cpu" or "cuda" or torch.Tensor.device :p
espnet2/legacy/nets/pytorch_backend/transformer/mask.py:9
next →1–100 of 9,880, ranked by callers