class_docstr: A builder class that allows to builds a multitrack unet model
  estimator. The built model estimator has a different behaviour when
  used in a train/eval mode and in predict mode.
  
  * In train/eval mode:
      It takes as input and outputs magnitude spectrogram
  * In predict mode:
      It takes as input and outputs waveform.
      The whole separation process is then done in this function
      for performance reason: it makes it possible to run the whole
      separation process (including STFT and inverse STFT) on GPU.
  
  Example:
  >>> from spleeter.model import EstimatorSpecBuilder
  >>> builder = EstimatorSpecBuilder()
  >>> builder.build_predict_model()
  >>> builder.build_evaluation_model()
  >>> builder.build_train_model()
  
  >>> from spleeter.model import model_fn
  >>> estimator = tf.estimator.Estimator(model_fn=model_fn, ...)
class_docstr_tok: ["A","builder","class","that","allows","to","builds","a","multitrack","unet","model","estimator",".","The","built","model","estimator","has","a","different","behaviour","when","used","in","a","train\/eval","mode","and","in","predict","mode",".","*","In","train\/eval","mode",":","It","takes","as","input","and","outputs","magnitude","spectrogram","*","In","predict","mode",":","It","takes","as","input","and","outputs","waveform",".","The","whole","separation","process","is","then","done","in","this","function","for","performance","reason",":","it","makes","it","possible","to","run","the","whole","separation","process","(","including","STFT","and","inverse","STFT",")","on","GPU",".","Example",":",">",">",">","from","spleeter.model","import","EstimatorSpecBuilder",">",">",">","builder","=","EstimatorSpecBuilder","(",")",">",">",">","builder.build_predict_model","(",")",">",">",">","builder.build_evaluation_model","(",")",">",">",">","builder.build_train_model","(",")",">",">",">","from","spleeter.model","import","model_fn",">",">",">","estimator","=","tf.estimator.Estimator","(","model_fn=model_fn",",","...",")"]
docstr: Default constructor. Depending on built model usage,
  the provided features should be different:
  
  * In train/eval mode:
      Features is a dictionary with a "mix_spectrogram" key,
      associated to the mix magnitude spectrogram.
  * In predict mode:
      Features is a dictionary with a "waveform" key,
      associated to the waveform of the sound to be separated.
  
  Parameters:
      features ():
          The input features for the estimator.
      params ():
          Some hyperparameters as a dictionary.
docstr_tok: ["Default","constructor",".","Depending","on","built","model","usage",",","the","provided","features","should","be","different",":","*","In","train\/eval","mode",":","Features","is","a","dictionary","with","a","``","mix_spectrogram","''","key",",","associated","to","the","mix","magnitude","spectrogram",".","*","In","predict","mode",":","Features","is","a","dictionary","with","a","``","waveform","''","key",",","associated","to","the","waveform","of","the","sound","to","be","separated",".","Parameters",":","features","(",")",":","The","input","features","for","the","estimator",".","params","(",")",":","Some","hyperparameters","as","a","dictionary","."]
code: def __init__(self, features: Dict, params: Dict) -> None:
      """
      Default constructor. Depending on built model usage,
      the provided features should be different:
  
      * In train/eval mode:
          Features is a dictionary with a "mix_spectrogram" key,
          associated to the mix magnitude spectrogram.
      * In predict mode:
          Features is a dictionary with a "waveform" key,
          associated to the waveform of the sound to be separated.
  
      Parameters:
          features ():
              The input features for the estimator.
          params ():
              Some hyperparameters as a dictionary.
      """
  
      self._features = features
      self._params = params
      # Get instrument name.
      self._mix_name = params["mix_name"]
      self._instruments = params["instrument_list"]
      # Get STFT/signals parameters
      self._n_channels = params["n_channels"]
      self._T = params["T"]
      self._F = params["F"]
      self._frame_length = params["frame_length"]
      self._frame_step = params["frame_step"]
  
imports: import importlib
  from typing import Any, Dict, Optional, Tuple
  import tensorflow
  from tensorflow.signal import hann_window, inverse_stft, stft
  from ..utils.tensor import pad_and_partition, pad_and_reshape
label_desc: Use image node_id 1 to create a new EstimatorSpecBuilder object from inherited base classes: object with example: obj = EstimatorSpecBuilder(features, params)