MCPcopy Create free account

hub / github.com/XuezheMax/flowseq / functions

Functions372 in github.com/XuezheMax/flowseq

↓ 1 callersFunctionarccosh
(x)
flownmt/flows/couplings/transform.py:55
↓ 1 callersFunctionarcsinh
(x)
flownmt/flows/couplings/transform.py:59
↓ 1 callersMethodbackward
(self, *inputs, **kwargs)
flownmt/flows/parallel/data_parallel.py:50
↓ 1 callersMethodbatch
Yield elements from data in chunks of batch_size.
flownmt/data/dataloader.py:365
↓ 1 callersFunctionbatch_iter
Yield elements from data in chunks of batch_size, where each chunk size is a multiple of batch_size_multiple. This is an extended version of
flownmt/data/dataloader.py:159
↓ 1 callersFunctionbucket_batch_iter
Yield elements from data in chunks of batch_size, where each chunk size is a multiple of batch_size_multiple. This is an extended version of t
flownmt/data/dataloader.py:189
↓ 1 callersMethodbwd
(z: torch.Tensor, mask: torch.Tensor, params)
flownmt/flows/couplings/transform.py:100
↓ 1 callersMethodby_name
(cls, name: str)
flownmt/modules/priors/prior.py:205
↓ 1 callersFunctioncreate_dataset
(args)
experiments/distributed.py:18
↓ 1 callersFunctiondiscretized_mix_logistic_loss
loss for discretized mixture logistic distribution Args: x: [batch, ] means: [batch, nmix] logscales: [batch, nmix]
flownmt/modules/priors/length_predictors/utils.py:7
↓ 1 callersFunctiondiscretized_mix_logistic_topk
topk for discretized mixture logistic distribution Args: means: [batch, nmix] logscales: [batch, nmix] logit_probs:,
flownmt/modules/priors/length_predictors/utils.py:62
↓ 1 callersMethodextra_repr
(self)
flownmt/nnet/weightnorm.py:21
↓ 1 callersMethodforward
Args: input: Tensor input tensor [batch, N1, N2, ..., Nl, in_features] mask: Tensor
flownmt/flows/linear.py:27
↓ 1 callersMethodforward
Args: input: Tensor input tensor [batch, N1, N2, ..., Nl, in_features] mask: Tensor
flownmt/flows/linear.py:119
↓ 1 callersMethodforward
(self, *inputs, **kwargs)
flownmt/flows/parallel/data_parallel.py:39
↓ 1 callersMethodfwdpass
Args: x: Tensor The random variable before flow h: list of object other conditional
flownmt/flows/flow.py:43
↓ 1 callersFunctionget_a_var
(obj)
flownmt/flows/parallel/parallel_apply.py:5
↓ 1 callersMethodget_dataset
(self)
flownmt/data/dataloader.py:330
↓ 1 callersFunctionget_sorted_wordlist
(path)
flownmt/data/dataloader.py:10
↓ 1 callersMethodinit
(self, tgt_sents, tgt_masks, src_enc, src_masks, init_scale=1.0, init_mu=True, init_var=True)
flownmt/modules/posteriors/shift_rnn.py:74
↓ 1 callersMethodinit
(self, tgt_sents, tgt_masks, src_enc, src_masks, init_scale=1.0, init_mu=True, init_var=True)
flownmt/modules/posteriors/transformer.py:50
↓ 1 callersMethodinit
(self, tgt_sents, tgt_masks, src_enc, src_masks, init_scale=1.0, init_mu=True, init_var=True)
flownmt/modules/posteriors/rnn.py:58
↓ 1 callersMethodinit
(self, data: torch.Tensor, mask: torch.Tensor, src: torch.Tensor, src_mask: torch.Tensor, init_scale=1.0)
flownmt/flows/couplings/coupling.py:154
↓ 1 callersFunctioninit_dataloader
(args, dataset)
experiments/translate.py:157
↓ 1 callersFunctioninit_dataloader
(args, dataset)
experiments/nmt.py:279
↓ 1 callersMethodinit_distributed
(self, rank, local_rank)
flownmt/flownmt.py:538
↓ 1 callersMethodinit_epoch
(self)
flownmt/data/dataloader.py:407
↓ 1 callersFunctioninit_model
(args, train_iter, flownmt)
experiments/nmt.py:299
↓ 1 callersMethodinit_net
(self, z: torch.Tensor, mask: torch.Tensor, src: torch.Tensor, src_mask: torch.Tensor, init_scale=1.0)
flownmt/flows/couplings/coupling.py:93
↓ 1 callersFunctioninit_posterior
(args, train_iter, flownmt)
experiments/nmt.py:314
↓ 1 callersMethodinit_posterior
(self, src_sents, tgt_sents, src_masks, tgt_masks, init_scale=1.0)
flownmt/flownmt.py:406
↓ 1 callersFunctioninit_prior
(args, train_iter, flownmt)
experiments/nmt.py:329
↓ 1 callersMethodinit_prior
(self, src_sents, tgt_sents, src_masks, tgt_masks, init_scale=1.0)
flownmt/flownmt.py:410
↓ 1 callersMethodload_core
(self, path, device, load_prior=True)
flownmt/flownmt.py:573
↓ 1 callersMethodloss
Args: ctx: Tensor tensor [batch, features] src_mask: Tensor tensor for source mask [
flownmt/modules/priors/length_predictors/predictor.py:19
↓ 1 callersFunctionmain
()
experiments/slurm.py:14
↓ 1 callersFunctionmain
()
experiments/distributed.py:46
↓ 1 callersFunctionmain
(args)
experiments/translate.py:166
↓ 1 callersFunctionmain
(args)
experiments/nmt.py:759
↓ 1 callersFunctionmake_positions
Replace non-padding symbols with their position numbers. Position numbers begin at padding_idx+1. Padding symbols are ignored.
flownmt/utils.py:151
↓ 1 callersMethodpad_tgt
(self, tgt)
flownmt/data/dataloader.py:322
↓ 1 callersFunctionparallel_apply
r"""Applies each `module` in :attr:`modules` in parallel on arguments contained in :attr:`inputs` (positional) and :attr:`kwargs_tup` (keyword)
flownmt/flows/parallel/parallel_apply.py:20
↓ 1 callersFunctionparse_args
()
experiments/options.py:5
↓ 1 callersFunctionparse_translate_args
()
experiments/options.py:48
↓ 1 callersMethodpredict
Args: ctx: Tensor tensor [batch, features] src_mask: Tensor tensor for source mask [b
flownmt/modules/priors/length_predictors/predictor.py:36
↓ 1 callersFunctionpretrain_model
(args, dataset, train_iter, val_iter, flownmt, zero_steps)
experiments/nmt.py:344
↓ 1 callersMethodreconstruct
(self, src_sents: torch.Tensor, tgt_sents: torch.Tensor, src_masks: torch.Tensor, tgt_mask
flownmt/flownmt.py:414
↓ 1 callersMethodreconstruct_loss
Args: src_sents: Tensor [batch, src_length] tensor for source sentences tgt_sents: Tensor [batch, tg
flownmt/flownmt.py:289
↓ 1 callersMethodregister
(cls, name: str)
flownmt/modules/priors/prior.py:201
↓ 1 callersMethodreset_parameters
(self)
flownmt/modules/encoders/transformer.py:27
↓ 1 callersMethodreset_parameters
(self)
flownmt/modules/encoders/rnn.py:30
↓ 1 callersMethodreset_parameters
(self)
flownmt/modules/encoders/encoder.py:18
↓ 1 callersMethodreset_parameters
(self)
flownmt/modules/posteriors/posterior.py:21
↓ 1 callersMethodreset_parameters
(self)
flownmt/modules/posteriors/transformer.py:31
↓ 1 callersMethodreset_parameters
(self, dim)
flownmt/modules/decoders/decoder.py:30
↓ 1 callersMethodreset_parameters
(self)
flownmt/modules/priors/length_predictors/diff_discretized_mix_logistic.py:28
↓ 1 callersMethodreset_parameters
(self)
flownmt/modules/priors/length_predictors/diff_softmax.py:34
↓ 1 callersMethodreset_parameters
(self)
flownmt/nnet/attention.py:40
↓ 1 callersMethodreset_parameters
(self)
flownmt/nnet/attention.py:126
↓ 1 callersMethodreset_parameters
(self)
flownmt/nnet/weightnorm.py:15
↓ 1 callersMethodreset_parameters
(self)
flownmt/nnet/weightnorm.py:55
↓ 1 callersMethodreset_parameters
(self)
flownmt/flows/actnorm.py:19
↓ 1 callersMethodreset_parameters
(self)
flownmt/flows/linear.py:19
↓ 1 callersMethodreset_parameters
(self)
flownmt/flows/linear.py:111
↓ 1 callersMethodsave_core
(self, path)
flownmt/flownmt.py:565
↓ 1 callersMethodset_length_unit
(self, length_unit)
flownmt/modules/priors/length_predictors/predictor.py:16
↓ 1 callersFunctionsetup
(args)
experiments/translate.py:116
↓ 1 callersFunctionsetup
(args)
experiments/nmt.py:181
↓ 1 callersMethodsync
(self)
flownmt/flows/linear.py:23
↓ 1 callersMethodsync
(self)
flownmt/flows/linear.py:115
↓ 1 callersFunctiontrain
(args, dataset, train_iter, val_iter, test_iter, flownmt)
experiments/nmt.py:500
↓ 1 callersFunctiontranslate
(epoch, dataset, dataloader, flownmt, result_path, log)
experiments/nmt.py:56
↓ 1 callersMethodtranslate_loss
Args: src_sents: Tensor [batch, src_length] tensor for source sentences tgt_sents: Tensor [batch, tg
flownmt/flownmt.py:317
↓ 1 callersMethodtranslate_sample
Args: src_sents: Tensor [batch, src_length] tensor for source sentences src_masks: Tensor [batch, sr
flownmt/flownmt.py:466
Method__init__
(self, encoder: Encoder, prior: Prior, posterior: Posterior, decoder: Decoder)
flownmt/flownmt.py:22
Method__init__
(self, vocab_size, embed_dim, padding_idx, num_layers, latent_dim, hidden_size, heads, dropout=0.0, max_length
flownmt/modules/encoders/transformer.py:59
Method__init__
(self, vocab_size, embed_dim, padding_idx, rnn_mode, num_layers, latent_dim, hidden_size, dropout=0.0)
flownmt/modules/encoders/rnn.py:58
Method__init__
(self, vocab_size, embed_dim, padding_idx)
flownmt/modules/encoders/encoder.py:13
Method__init__
(self, vocab_size, embed_dim, padding_idx, rnn_mode, num_layers, latent_dim, hidden_size, bid
flownmt/modules/posteriors/shift_rnn.py:111
Method__init__
(self, vocab_size, embed_dim, padding_idx, _shared_embed=None)
flownmt/modules/posteriors/posterior.py:13
Method__init__
(self, vocab_size, embed_dim, padding_idx, num_layers, latent_dim, hidden_size, heads, dropou
flownmt/modules/posteriors/transformer.py:74
Method__init__
(self, vocab_size, embed_dim, padding_idx, rnn_mode, num_layers, latent_dim, hidden_size, use
flownmt/modules/posteriors/rnn.py:84
Method__init__
(self, vocab_size, latent_dim, label_smoothing=0., _shared_weight=None)
flownmt/modules/decoders/decoder.py:14
Method__init__
(self, vocab_size, latent_dim, hidden_size, dropout=0.0, label_smoothing=0., _shared_weight=None)
flownmt/modules/decoders/simple.py:15
Method__init__
(self, vocab_size, latent_dim, num_layers, hidden_size, heads, label_smoothing=0., dropout=0.
flownmt/modules/decoders/transformer.py:17
Method__init__
(self, vocab_size, latent_dim, rnn_mode, num_layers, hidden_size, bidirectional=True, dropout
flownmt/modules/decoders/rnn.py:16
Method__init__
(self, flow: NMTFlow, length_predictor: LengthPredictor)
flownmt/modules/priors/prior.py:16
Method__init__
(self)
flownmt/modules/priors/length_predictors/predictor.py:12
Method__init__
(self, features, max_src_length, diff_range, nmix=1, dropout=0.0)
flownmt/modules/priors/length_predictors/diff_discretized_mix_logistic.py:12
Method__init__
(self, features, max_src_length, diff_range, dropout=0.0, label_smoothing=0.)
flownmt/modules/priors/length_predictors/diff_softmax.py:12
Method__init__
(self, encoding_dim, padding_idx, init_size=1024)
flownmt/nnet/positional_encoding.py:13
Method__init__
Args: model_dim: int the input dimension for keys, queries and values heads: int num
flownmt/nnet/attention.py:102
Method__init__
(self, features, hidden_features, dropout=0.0)
flownmt/nnet/attention.py:236
Method__init__
(self, label_smoothing)
flownmt/nnet/criterion.py:10
Method__init__
(self, model_dim, hidden_dim, heads, dropout=0.0, mask_diag=False)
flownmt/nnet/transformer.py:24
Method__init__
(self, in_channels, out_channels, kernel_size, stride=1, padding=0, dilation=1, groups=1, bia
flownmt/nnet/weightnorm.py:48
Method__init__
(self, params, lr=1e-3, betas=(0.9, 0.999), eps=1e-8, weight_decay=0, amsgrad=False)
flownmt/optim/adamw.py:33
Method__init__
(self, optimizer, warmup_steps, init_lr, last_epoch=-1)
flownmt/optim/lr_scheduler.py:63
Method__init__
(self, optimizer, gamma, warmup_steps, init_lr, last_epoch=-1)
flownmt/optim/lr_scheduler.py:94
Method__init__
(self, data_path, src_lang, tgt_lang, src_vocab_path, tgt_vocab_path, src_max_vocab, tgt_max_vocab,
flownmt/data/dataloader.py:34
← previousnext →101–200 of 372, ranked by callers