docstr: Get smoothed sampling porbability by languages. This helps low resource
  languages by upsampling them.
docstr_tok: ["Get","smoothed","sampling","porbability","by","languages",".","This","helps","low","resource","languages","by","upsampling","them","."]
code: def _get_sample_prob(self, dataset_lens):
      """
      Get smoothed sampling porbability by languages. This helps low resource
      languages by upsampling them.
      """
      prob = dataset_lens / dataset_lens.sum()
      smoothed_prob = prob**self.args.multilang_sampling_alpha
      smoothed_prob = smoothed_prob / smoothed_prob.sum()
      return smoothed_prob
  
imports: import itertools
  import logging
  import os
  import re
  import numpy
  import torch
  from examples.speech_text_joint_to_text.data.pair_denoising_dataset import LanguagePairDenoisingDataset
  from fairseq import utils
  from fairseq.data import ConcatDataset, Dictionary, LanguagePairDataset, ResamplingDataset, TransformEosConcatLangPairDataset, TransformEosLangPairDataset, data_utils, indexed_dataset
  from fairseq.data.encoders.utils import get_whole_word_mask
  from fairseq.tasks import register_task
  from fairseq.tasks.translation import TranslationTask
label_desc: Use image node_id 5 for calling the PairedDenoisingTask obj's underlying member method code with example usage: obj._get_sample_prob(dataset_lens) and returns: smoothed_prob