RECODE-H / annotations /annotation_27 /function_info.json
mcy98's picture
Upload folder using huggingface_hub
e89a301 verified
Raw History Blame Contribute Delete
50.2 kB
[ { "function_name": "DFT_series_decomp.__init__", "file_path": "models/TimeMixer.py", "function_calls": [ { "function_call_name": "super", "functionality": "Initializes the parent class (nn.Module).", "input": "", "output": "DFT_series_decomp object", "location_or_namespace": "builtins" } ] }, { "function_name": "DFT_series_decomp.forward", "file_path": "models/TimeMixer.py", "function_calls": [ { "function_call_name": "torch.fft.rfft", "functionality": "Computes the one-dimensional discrete Fourier Transform for real input.", "input": "x (Tensor)", "output": "Tensor", "location_or_namespace": "torch.fft" }, { "function_call_name": "abs", "functionality": "Computes the absolute value of each element in the input tensor.", "input": "xf (Tensor)", "output": "Tensor", "location_or_namespace": "builtins" }, { "function_call_name": "torch.topk", "functionality": "Returns the k largest elements of the given input tensor along a given dimension.", "input": "freq (Tensor), 5 (int)", "output": "tuple (top_k_freq (Tensor), top_list (Tensor))", "location_or_namespace": "torch" }, { "function_call_name": "top_k_freq.min", "functionality": "Returns the minimum value of all elements in the input tensor.", "input": "", "output": "Tensor", "location_or_namespace": "torch.Tensor" }, { "function_call_name": "torch.fft.irfft", "functionality": "Computes the one-dimensional inverse discrete Fourier Transform for real output.", "input": "xf (Tensor)", "output": "Tensor", "location_or_namespace": "torch.fft" } ] }, { "function_name": "MultiScaleSeasonMixing.__init__", "file_path": "models/TimeMixer.py", "function_calls": [ { "function_call_name": "super", "functionality": "Initializes the parent class (nn.Module).", "input": "", "output": "MultiScaleSeasonMixing object", "location_or_namespace": "builtins" }, { "function_call_name": "torch.nn.ModuleList", "functionality": "Holds submodules in a list.", "input": "[nn.Sequential(...)]", "output": "ModuleList object", "location_or_namespace": "torch.nn" }, { "function_call_name": "torch.nn.Sequential", "functionality": "A sequential container of modules.", "input": "torch.nn.Linear, nn.GELU, torch.nn.Linear", "output": "Sequential object", "location_or_namespace": "torch.nn" }, { "function_call_name": "torch.nn.Linear", "functionality": "Applies a linear transformation to the incoming data.", "input": "in_features (int), out_features (int)", "output": "Linear object", "location_or_namespace": "torch.nn" }, { "function_call_name": "torch.nn.GELU", "functionality": "Applies the Gaussian Error Linear Unit function element-wise.", "input": "", "output": "GELU object", "location_or_namespace": "torch.nn" }, { "function_call_name": "range", "functionality": "Generates a sequence of numbers.", "input": "configs.down_sampling_layers (int)", "output": "iterator", "location_or_namespace": "builtins" } ] }, { "function_name": "MultiScaleSeasonMixing.forward", "file_path": "models/TimeMixer.py", "function_calls": [ { "function_call_name": "out_high.permute", "functionality": "Permutes the dimensions of the tensor.", "input": "0, 2, 1 (int, int, int)", "output": "Tensor", "location_or_namespace": "torch.Tensor" }, { "function_call_name": "range", "functionality": "Generates a sequence of numbers.", "input": "len(season_list) - 1 (int)", "output": "iterator", "location_or_namespace": "builtins" }, { "function_call_name": "len", "functionality": "Returns the length of an object.", "input": "season_list (list)", "output": "int", "location_or_namespace": "builtins" }, { "function_call_name": "self.down_sampling_layers[i]", "functionality": "Accesses a specific sequential layer from the ModuleList and passes data through it.", "input": "out_high (Tensor)", "output": "Tensor", "location_or_namespace": "TimeMixer/models/TimeMixer.py" }, { "function_call_name": "out_season_list.append", "functionality": "Appends an element to the list.", "input": "out_high.permute(0, 2, 1) (Tensor)", "output": "None", "location_or_namespace": "builtins.list" } ] }, { "function_name": "MultiScaleTrendMixing.__init__", "file_path": "models/TimeMixer.py", "function_calls": [ { "function_call_name": "super", "functionality": "Initializes the parent class (nn.Module).", "input": "", "output": "MultiScaleTrendMixing object", "location_or_namespace": "builtins" }, { "function_call_name": "torch.nn.ModuleList", "functionality": "Holds submodules in a list.", "input": "[nn.Sequential(...)]", "output": "ModuleList object", "location_or_namespace": "torch.nn" }, { "function_call_name": "torch.nn.Sequential", "functionality": "A sequential container of modules.", "input": "torch.nn.Linear, nn.GELU, torch.nn.Linear", "output": "Sequential object", "location_or_namespace": "torch.nn" }, { "function_call_name": "torch.nn.Linear", "functionality": "Applies a linear transformation to the incoming data.", "input": "in_features (int), out_features (int)", "output": "Linear object", "location_or_namespace": "torch.nn" }, { "function_call_name": "torch.nn.GELU", "functionality": "Applies the Gaussian Error Linear Unit function element-wise.", "input": "", "output": "GELU object", "location_or_namespace": "torch.nn" }, { "function_call_name": "reversed", "functionality": "Returns a reverse iterator.", "input": "range(configs.down_sampling_layers)", "output": "iterator", "location_or_namespace": "builtins" }, { "function_call_name": "range", "functionality": "Generates a sequence of numbers.", "input": "configs.down_sampling_layers (int)", "output": "iterator", "location_or_namespace": "builtins" } ] }, { "function_name": "MultiScaleTrendMixing.forward", "file_path": "models/TimeMixer.py", "function_calls": [ { "function_call_name": "trend_list.copy", "functionality": "Returns a shallow copy of the list.", "input": "", "output": "list", "location_or_namespace": "builtins.list" }, { "function_call_name": "trend_list_reverse.reverse", "functionality": "Reverses the elements of the list in place.", "input": "", "output": "None", "location_or_namespace": "builtins.list" }, { "function_call_name": "out_low.permute", "functionality": "Permutes the dimensions of the tensor.", "input": "0, 2, 1 (int, int, int)", "output": "Tensor", "location_or_namespace": "torch.Tensor" }, { "function_call_name": "range", "functionality": "Generates a sequence of numbers.", "input": "len(trend_list_reverse) - 1 (int)", "output": "iterator", "location_or_namespace": "builtins" }, { "function_call_name": "len", "functionality": "Returns the length of an object.", "input": "trend_list_reverse (list)", "output": "int", "location_or_namespace": "builtins" }, { "function_call_name": "self.up_sampling_layers[i]", "functionality": "Accesses a specific sequential layer from the ModuleList and passes data through it.", "input": "out_low (Tensor)", "output": "Tensor", "location_or_namespace": "TimeMixer/models/TimeMixer.py" }, { "function_call_name": "out_trend_list.append", "functionality": "Appends an element to the list.", "input": "out_low.permute(0, 2, 1) (Tensor)", "output": "None", "location_or_namespace": "builtins.list" }, { "function_call_name": "out_trend_list.reverse", "functionality": "Reverses the elements of the list in place.", "input": "", "output": "None", "location_or_namespace": "builtins.list" } ] }, { "function_name": "PastDecomposableMixing.__init__", "file_path": "models/TimeMixer.py", "function_calls": [ { "function_call_name": "super", "functionality": "Initializes the parent class (nn.Module).", "input": "", "output": "PastDecomposableMixing object", "location_or_namespace": "builtins" }, { "function_call_name": "torch.nn.LayerNorm", "functionality": "Applies Layer Normalization over a mini-batch of inputs.", "input": "configs.d_model (int)", "output": "LayerNorm object", "location_or_namespace": "torch.nn" }, { "function_call_name": "torch.nn.Dropout", "functionality": "During training, randomly zeroes some of the elements of the input tensor with probability p.", "input": "configs.dropout (float)", "output": "Dropout object", "location_or_namespace": "torch.nn" }, { "function_call_name": "series_decomp", "functionality": "Decomposes a time series into trend and seasonal components using a moving average.", "input": "configs.moving_avg (int)", "output": "series_decomp object", "location_or_namespace": "layers.Autoformer_EncDec" }, { "function_call_name": "DFT_series_decomp", "functionality": "Decomposes a time series into trend and seasonal components using Discrete Fourier Transform.", "input": "configs.top_k (int)", "output": "DFT_series_decomp object", "location_or_namespace": "TimeMixer/models/TimeMixer.py" }, { "function_call_name": "ValueError", "functionality": "Raises a ValueError exception.", "input": "'decompsition is error' (str)", "output": "None", "location_or_namespace": "builtins" }, { "function_call_name": "torch.nn.Sequential", "functionality": "A sequential container of modules.", "input": "torch.nn.Linear, nn.GELU, torch.nn.Linear", "output": "Sequential object", "location_or_namespace": "torch.nn" }, { "function_call_name": "torch.nn.Linear", "functionality": "Applies a linear transformation to the incoming data.", "input": "in_features (int), out_features (int)", "output": "Linear object", "location_or_namespace": "torch.nn" }, { "function_call_name": "torch.nn.GELU", "functionality": "Applies the Gaussian Error Linear Unit function element-wise.", "input": "", "output": "GELU object", "location_or_namespace": "torch.nn" }, { "function_call_name": "MultiScaleSeasonMixing", "functionality": "Initializes the MultiScaleSeasonMixing module for bottom-up mixing of seasonal patterns.", "input": "configs (object)", "output": "MultiScaleSeasonMixing object", "location_or_namespace": "TimeMixer/models/TimeMixer.py" }, { "function_call_name": "MultiScaleTrendMixing", "functionality": "Initializes the MultiScaleTrendMixing module for top-down mixing of trend patterns.", "input": "configs (object)", "output": "MultiScaleTrendMixing object", "location_or_namespace": "TimeMixer/models/TimeMixer.py" } ] }, { "function_name": "PastDecomposableMixing.forward", "file_path": "models/TimeMixer.py", "function_calls": [ { "function_call_name": "x.size", "functionality": "Returns the size of the self tensor.", "input": "", "output": "torch.Size", "location_or_namespace": "torch.Tensor" }, { "function_call_name": "length_list.append", "functionality": "Appends an element to the list.", "input": "T (int)", "output": "None", "location_or_namespace": "builtins.list" }, { "function_call_name": "self.decompsition", "functionality": "Decomposes the input tensor into seasonal and trend components.", "input": "x (Tensor)", "output": "tuple (season (Tensor), trend (Tensor))", "location_or_namespace": "TimeMixer/models/TimeMixer.py or layers.Autoformer_EncDec" }, { "function_call_name": "self.cross_layer", "functionality": "Applies a feed-forward network for channel interaction.", "input": "season (Tensor) or trend (Tensor)", "output": "Tensor", "location_or_namespace": "TimeMixer/models/TimeMixer.py" }, { "function_call_name": "season.permute", "functionality": "Permutes the dimensions of the tensor.", "input": "0, 2, 1 (int, int, int)", "output": "Tensor", "location_or_namespace": "torch.Tensor" }, { "function_call_name": "season_list.append", "functionality": "Appends an element to the list.", "input": "season.permute(0, 2, 1) (Tensor)", "output": "None", "location_or_namespace": "builtins.list" }, { "function_call_name": "trend_list.append", "functionality": "Appends an element to the list.", "input": "trend.permute(0, 2, 1) (Tensor)", "output": "None", "location_or_namespace": "builtins.list" }, { "function_call_name": "self.mixing_multi_scale_season", "functionality": "Performs bottom-up mixing of multi-scale seasonal components.", "input": "season_list (list of Tensors)", "output": "list of Tensors", "location_or_namespace": "TimeMixer/models/TimeMixer.py" }, { "function_call_name": "self.mixing_multi_scale_trend", "functionality": "Performs top-down mixing of multi-scale trend components.", "input": "trend_list (list of Tensors)", "output": "list of Tensors", "location_or_namespace": "TimeMixer/models/TimeMixer.py" }, { "function_call_name": "zip", "functionality": "Returns an iterator of tuples, where the i-th tuple contains the i-th element from each of the argument sequences or iterables.", "input": "x_list, out_season_list, out_trend_list, length_list", "output": "iterator", "location_or_namespace": "builtins" }, { "function_call_name": "self.out_cross_layer", "functionality": "Applies a feed-forward network for output channel interaction.", "input": "out (Tensor)", "output": "Tensor", "location_or_namespace": "TimeMixer/models/TimeMixer.py" }, { "function_call_name": "out_list.append", "functionality": "Appends an element to the list.", "input": "out[:, :length, :] (Tensor)", "output": "None", "location_or_namespace": "builtins.list" } ] }, { "function_name": "Model.__init__", "file_path": "models/TimeMixer.py", "function_calls": [ { "function_call_name": "super", "functionality": "Initializes the parent class (nn.Module).", "input": "", "output": "Model object", "location_or_namespace": "builtins" }, { "function_call_name": "torch.nn.ModuleList", "functionality": "Holds submodules in a list.", "input": "[PastDecomposableMixing(configs)] or [Normalize(...)] or [torch.nn.Linear(...)]", "output": "ModuleList object", "location_or_namespace": "torch.nn" }, { "function_call_name": "PastDecomposableMixing", "functionality": "Initializes the PastDecomposableMixing block.", "input": "configs (object)", "output": "PastDecomposableMixing object", "location_or_namespace": "TimeMixer/models/TimeMixer.py" }, { "function_call_name": "range", "functionality": "Generates a sequence of numbers.", "input": "configs.e_layers (int) or configs.down_sampling_layers + 1 (int)", "output": "iterator", "location_or_namespace": "builtins" }, { "function_call_name": "series_decomp", "functionality": "Decomposes a time series into trend and seasonal components using a moving average.", "input": "configs.moving_avg (int)", "output": "series_decomp object", "location_or_namespace": "layers.Autoformer_EncDec" }, { "function_call_name": "DataEmbedding_wo_pos", "functionality": "Embeds input data without positional encoding.", "input": "1 or configs.enc_in (int), configs.d_model (int), configs.embed (str), configs.freq (str), configs.dropout (float)", "output": "DataEmbedding_wo_pos object", "location_or_namespace": "layers.Embed" }, { "function_call_name": "Normalize", "functionality": "Applies normalization to the input tensor.", "input": "self.configs.enc_in (int), affine=True (bool), non_norm (bool)", "output": "Normalize object", "location_or_namespace": "layers.StandardNorm" }, { "function_call_name": "torch.nn.Linear", "functionality": "Applies a linear transformation to the incoming data.", "input": "in_features (int), out_features (int), bias (bool, optional)", "output": "Linear object", "location_or_namespace": "torch.nn" }, { "function_call_name": "torch.nn.Dropout", "functionality": "During training, randomly zeroes some of the elements of the input tensor with probability p.", "input": "configs.dropout (float)", "output": "Dropout object", "location_or_namespace": "torch.nn" } ] }, { "function_name": "Model.out_projection", "file_path": "models/TimeMixer.py", "function_calls": [ { "function_call_name": "self.projection_layer", "functionality": "Applies a linear projection to the input tensor.", "input": "dec_out (Tensor)", "output": "Tensor", "location_or_namespace": "TimeMixer/models/TimeMixer.py" }, { "function_call_name": "out_res.permute", "functionality": "Permutes the dimensions of the tensor.", "input": "0, 2, 1 (int, int, int)", "output": "Tensor", "location_or_namespace": "torch.Tensor" }, { "function_call_name": "self.out_res_layers[i]", "functionality": "Applies a linear layer for residual connection.", "input": "out_res (Tensor)", "output": "Tensor", "location_or_namespace": "TimeMixer/models/TimeMixer.py" }, { "function_call_name": "self.regression_layers[i]", "functionality": "Applies a linear layer for regression.", "input": "out_res (Tensor)", "output": "Tensor", "location_or_namespace": "TimeMixer/models/TimeMixer.py" } ] }, { "function_name": "Model.pre_enc", "file_path": "models/TimeMixer.py", "function_calls": [ { "function_call_name": "self.preprocess", "functionality": "Decomposes the input tensor using series_decomp.", "input": "x (Tensor)", "output": "tuple (x_1 (Tensor), x_2 (Tensor))", "location_or_namespace": "TimeMixer/models/TimeMixer.py or layers.Autoformer_EncDec" }, { "function_call_name": "out1_list.append", "functionality": "Appends an element to the list.", "input": "x_1 (Tensor)", "output": "None", "location_or_namespace": "builtins.list" }, { "function_call_name": "out2_list.append", "functionality": "Appends an element to the list.", "input": "x_2 (Tensor)", "output": "None", "location_or_namespace": "builtins.list" } ] }, { "function_name": "Model.__multi_scale_process_inputs", "file_path": "models/TimeMixer.py", "function_calls": [ { "function_call_name": "torch.nn.MaxPool1d", "functionality": "Applies a 1D max pooling over an input signal composed of several input planes.", "input": "self.configs.down_sampling_window (int), return_indices=False (bool)", "output": "MaxPool1d object", "location_or_namespace": "torch.nn" }, { "function_call_name": "torch.nn.AvgPool1d", "functionality": "Applies a 1D average pooling over an input signal composed of several input planes.", "input": "self.configs.down_sampling_window (int)", "output": "AvgPool1d object", "location_or_namespace": "torch.nn" }, { "function_call_name": "torch.nn.Conv1d", "functionality": "Applies a 1D convolution over an input signal composed of several input planes.", "input": "in_channels (int), out_channels (int), kernel_size=3 (int), padding (int), stride (int), padding_mode='circular' (str), bias=False (bool)", "output": "Conv1d object", "location_or_namespace": "torch.nn" }, { "function_call_name": "x_enc.permute", "functionality": "Permutes the dimensions of the tensor.", "input": "0, 2, 1 (int, int, int)", "output": "Tensor", "location_or_namespace": "torch.Tensor" }, { "function_call_name": "x_enc_sampling_list.append", "functionality": "Appends an element to the list.", "input": "x_enc.permute(0, 2, 1) (Tensor) or x_enc_sampling.permute(0, 2, 1) (Tensor)", "output": "None", "location_or_namespace": "builtins.list" }, { "function_call_name": "x_mark_sampling_list.append", "functionality": "Appends an element to the list.", "input": "x_mark_enc (Tensor) or x_mark_enc_mark_ori[:, ::self.configs.down_sampling_window, :] (Tensor)", "output": "None", "location_or_namespace": "builtins.list" }, { "function_call_name": "range", "functionality": "Generates a sequence of numbers.", "input": "self.configs.down_sampling_layers (int)", "output": "iterator", "location_or_namespace": "builtins" }, { "function_call_name": "down_pool", "functionality": "Applies the down-sampling operation (MaxPool1d, AvgPool1d, or Conv1d).", "input": "x_enc_ori (Tensor)", "output": "Tensor", "location_or_namespace": "torch.nn" } ] }, { "function_name": "Model.forecast", "file_path": "models/TimeMixer.py", "function_calls": [ { "function_call_name": "self.__multi_scale_process_inputs", "functionality": "Processes input tensors to create multi-scale versions.", "input": "x_enc (Tensor), x_mark_enc (Tensor)", "output": "tuple (x_enc_list (list of Tensors), x_mark_enc_list (list of Tensors or None))", "location_or_namespace": "TimeMixer/models/TimeMixer.py" }, { "function_call_name": "zip", "functionality": "Returns an iterator of tuples, where the i-th tuple contains the i-th element from each of the argument sequences or iterables.", "input": "range(len(x_enc)), x_enc, x_mark_enc or range(len(x_enc)), x_enc or range(len(x_list[0])), x_list[0], x_mark_list or range(len(x_list[0])), x_list[0]", "output": "iterator", "location_or_namespace": "builtins" }, { "function_call_name": "range", "functionality": "Generates a sequence of numbers.", "input": "len(x_enc) (int) or len(x_list[0]) (int) or self.layer (int)", "output": "iterator", "location_or_namespace": "builtins" }, { "function_call_name": "len", "functionality": "Returns the length of an object.", "input": "x_enc (list) or x_list[0] (list)", "output": "int", "location_or_namespace": "builtins" }, { "function_call_name": "x.size", "functionality": "Returns the size of the self tensor.", "input": "", "output": "torch.Size", "location_or_namespace": "torch.Tensor" }, { "function_call_name": "self.normalize_layers[i]", "functionality": "Applies normalization to the input tensor.", "input": "x (Tensor), 'norm' (str)", "output": "Tensor", "location_or_namespace": "TimeMixer/models/TimeMixer.py or layers.StandardNorm" }, { "function_call_name": "x.permute", "functionality": "Permutes the dimensions of the tensor.", "input": "0, 2, 1 (int, int, int)", "output": "Tensor", "location_or_namespace": "torch.Tensor" }, { "function_call_name": "x.contiguous", "functionality": "Returns a contiguous in memory tensor containing the same data as self tensor.", "input": "", "output": "Tensor", "location_or_namespace": "torch.Tensor" }, { "function_call_name": "x.reshape", "functionality": "Returns a tensor with the same data and number of elements as self but with the specified shape.", "input": "B * N (int), T (int), 1 (int)", "output": "Tensor", "location_or_namespace": "torch.Tensor" }, { "function_call_name": "x_list.append", "functionality": "Appends an element to the list.", "input": "x (Tensor)", "output": "None", "location_or_namespace": "builtins.list" }, { "function_call_name": "x_mark.repeat", "functionality": "Repeats this tensor along the specified dimensions.", "input": "N (int), 1 (int), 1 (int)", "output": "Tensor", "location_or_namespace": "torch.Tensor" }, { "function_call_name": "x_mark_list.append", "functionality": "Appends an element to the list.", "input": "x_mark (Tensor)", "output": "None", "location_or_namespace": "builtins.list" }, { "function_call_name": "self.pre_enc", "functionality": "Pre-processes the input list, potentially decomposing if not channel independent.", "input": "x_list (list of Tensors)", "output": "tuple (list of Tensors, list of Tensors or None)", "location_or_namespace": "TimeMixer/models/TimeMixer.py" }, { "function_call_name": "self.enc_embedding", "functionality": "Embeds the input tensor.", "input": "x (Tensor), x_mark (Tensor or None)", "output": "Tensor", "location_or_namespace": "TimeMixer/models/TimeMixer.py or layers.Embed" }, { "function_call_name": "enc_out_list.append", "functionality": "Appends an element to the list.", "input": "enc_out (Tensor)", "output": "None", "location_or_namespace": "builtins.list" }, { "function_call_name": "self.pdm_blocks[i]", "functionality": "Applies the i-th PastDecomposableMixing block.", "input": "enc_out_list (list of Tensors)", "output": "list of Tensors", "location_or_namespace": "TimeMixer/models/TimeMixer.py" }, { "function_call_name": "self.future_multi_mixing", "functionality": "Performs future multi-predictor mixing.", "input": "B (int), enc_out_list (list of Tensors), x_list (tuple of lists of Tensors or list of Tensors)", "output": "list of Tensors", "location_or_namespace": "TimeMixer/models/TimeMixer.py" }, { "function_call_name": "torch.stack", "functionality": "Concatenates a sequence of tensors along a new dimension.", "input": "dec_out_list (list of Tensors), dim=-1 (int)", "output": "Tensor", "location_or_namespace": "torch" }, { "function_call_name": "torch.Tensor.sum", "functionality": "Returns the sum of all elements in the input tensor.", "input": "-1 (int)", "output": "Tensor", "location_or_namespace": "torch.Tensor" }, { "function_call_name": "self.normalize_layers[0]", "functionality": "Applies denormalization to the output tensor.", "input": "dec_out (Tensor), 'denorm' (str)", "output": "Tensor", "location_or_namespace": "TimeMixer/models/TimeMixer.py or layers.StandardNorm" } ] }, { "function_name": "Model.future_multi_mixing", "file_path": "models/TimeMixer.py", "function_calls": [ { "function_call_name": "zip", "functionality": "Returns an iterator of tuples, where the i-th tuple contains the i-th element from each of the argument sequences or iterables.", "input": "range(len(x_list)), enc_out_list or range(len(x_list[0])), enc_out_list, x_list[1]", "output": "iterator", "location_or_namespace": "builtins" }, { "function_call_name": "range", "functionality": "Generates a sequence of numbers.", "input": "len(x_list) (int) or len(x_list[0]) (int)", "output": "iterator", "location_or_namespace": "builtins" }, { "function_call_name": "len", "functionality": "Returns the length of an object.", "input": "x_list (list) or x_list[0] (list)", "output": "int", "location_or_namespace": "builtins" }, { "function_call_name": "self.predict_layers[i]", "functionality": "Applies a linear layer for prediction.", "input": "enc_out.permute(0, 2, 1) (Tensor)", "output": "Tensor", "location_or_namespace": "TimeMixer/models/TimeMixer.py" }, { "function_call_name": "enc_out.permute", "functionality": "Permutes the dimensions of the tensor.", "input": "0, 2, 1 (int, int, int)", "output": "Tensor", "location_or_namespace": "torch.Tensor" }, { "function_call_name": "dec_out.permute", "functionality": "Permutes the dimensions of the tensor.", "input": "0, 2, 1 (int, int, int)", "output": "Tensor", "location_or_namespace": "torch.Tensor" }, { "function_call_name": "self.projection_layer", "functionality": "Applies a linear projection to the input tensor.", "input": "dec_out (Tensor)", "output": "Tensor", "location_or_namespace": "TimeMixer/models/TimeMixer.py" }, { "function_call_name": "dec_out.reshape", "functionality": "Returns a tensor with the same data and number of elements as self but with the specified shape.", "input": "B (int), self.configs.c_out (int), self.pred_len (int)", "output": "Tensor", "location_or_namespace": "torch.Tensor" }, { "function_call_name": "dec_out.contiguous", "functionality": "Returns a contiguous in memory tensor containing the same data as self tensor.", "input": "", "output": "Tensor", "location_or_namespace": "torch.Tensor" }, { "function_call_name": "dec_out_list.append", "functionality": "Appends an element to the list.", "input": "dec_out (Tensor)", "output": "None", "location_or_namespace": "builtins.list" }, { "function_call_name": "self.out_projection", "functionality": "Applies output projection with residual connection.", "input": "dec_out (Tensor), i (int), out_res (Tensor)", "output": "Tensor", "location_or_namespace": "TimeMixer/models/TimeMixer.py" } ] }, { "function_name": "Model.classification", "file_path": "models/TimeMixer.py", "function_calls": [ { "function_call_name": "self.__multi_scale_process_inputs", "functionality": "Processes input tensors to create multi-scale versions.", "input": "x_enc (Tensor), None", "output": "tuple (x_enc_list (list of Tensors), None)", "location_or_namespace": "TimeMixer/models/TimeMixer.py" }, { "function_call_name": "self.enc_embedding", "functionality": "Embeds the input tensor.", "input": "x (Tensor), None", "output": "Tensor", "location_or_namespace": "TimeMixer/models/TimeMixer.py or layers.Embed" }, { "function_call_name": "enc_out_list.append", "functionality": "Appends an element to the list.", "input": "enc_out (Tensor)", "output": "None", "location_or_namespace": "builtins.list" }, { "function_call_name": "range", "functionality": "Generates a sequence of numbers.", "input": "self.layer (int)", "output": "iterator", "location_or_namespace": "builtins" }, { "function_call_name": "self.pdm_blocks[i]", "functionality": "Applies the i-th PastDecomposableMixing block.", "input": "enc_out_list (list of Tensors)", "output": "list of Tensors", "location_or_namespace": "TimeMixer/models/TimeMixer.py" }, { "function_call_name": "self.act", "functionality": "Applies the GELU activation function.", "input": "enc_out (Tensor)", "output": "Tensor", "location_or_namespace": "torch.nn.functional" }, { "function_call_name": "self.dropout", "functionality": "Applies dropout to the input tensor.", "input": "output (Tensor)", "output": "Tensor", "location_or_namespace": "TimeMixer/models/TimeMixer.py or torch.nn" }, { "function_call_name": "x_mark_enc.unsqueeze", "functionality": "Returns a new tensor with a dimension of size one inserted at the specified position.", "input": "-1 (int)", "output": "Tensor", "location_or_namespace": "torch.Tensor" }, { "function_call_name": "output.reshape", "functionality": "Returns a tensor with the same data and number of elements as self but with the specified shape.", "input": "output.shape[0] (int), -1 (int)", "output": "Tensor", "location_or_namespace": "torch.Tensor" }, { "function_call_name": "self.projection", "functionality": "Applies a linear layer for classification projection.", "input": "output (Tensor)", "output": "Tensor", "location_or_namespace": "TimeMixer/models/TimeMixer.py" } ] }, { "function_name": "Model.anomaly_detection", "file_path": "models/TimeMixer.py", "function_calls": [ { "function_call_name": "x_enc.size", "functionality": "Returns the size of the self tensor.", "input": "", "output": "torch.Size", "location_or_namespace": "torch.Tensor" }, { "function_call_name": "self.__multi_scale_process_inputs", "functionality": "Processes input tensors to create multi-scale versions.", "input": "x_enc (Tensor), None", "output": "tuple (x_enc_list (list of Tensors), None)", "location_or_namespace": "TimeMixer/models/TimeMixer.py" }, { "function_call_name": "zip", "functionality": "Returns an iterator of tuples, where the i-th tuple contains the i-th element from each of the argument sequences or iterables.", "input": "range(len(x_enc)), x_enc", "output": "iterator", "location_or_namespace": "builtins" }, { "function_call_name": "range", "functionality": "Generates a sequence of numbers.", "input": "len(x_enc) (int) or self.layer (int)", "output": "iterator", "location_or_namespace": "builtins" }, { "function_call_name": "len", "functionality": "Returns the length of an object.", "input": "x_enc (list)", "output": "int", "location_or_namespace": "builtins" }, { "function_call_name": "self.normalize_layers[i]", "functionality": "Applies normalization to the input tensor.", "input": "x (Tensor), 'norm' (str)", "output": "Tensor", "location_or_namespace": "TimeMixer/models/TimeMixer.py or layers.StandardNorm" }, { "function_call_name": "x.permute", "functionality": "Permutes the dimensions of the tensor.", "input": "0, 2, 1 (int, int, int)", "output": "Tensor", "location_or_namespace": "torch.Tensor" }, { "function_call_name": "x.contiguous", "functionality": "Returns a contiguous in memory tensor containing the same data as self tensor.", "input": "", "output": "Tensor", "location_or_namespace": "torch.Tensor" }, { "function_call_name": "x.reshape", "functionality": "Returns a tensor with the same data and number of elements as self but with the specified shape.", "input": "B * N (int), T (int), 1 (int)", "output": "Tensor", "location_or_namespace": "torch.Tensor" }, { "function_call_name": "x_list.append", "functionality": "Appends an element to the list.", "input": "x (Tensor)", "output": "None", "location_or_namespace": "builtins.list" }, { "function_call_name": "self.enc_embedding", "functionality": "Embeds the input tensor.", "input": "x (Tensor), None", "output": "Tensor", "location_or_namespace": "TimeMixer/models/TimeMixer.py or layers.Embed" }, { "function_call_name": "enc_out_list.append", "functionality": "Appends an element to the list.", "input": "enc_out (Tensor)", "output": "None", "location_or_namespace": "builtins.list" }, { "function_call_name": "self.pdm_blocks[i]", "functionality": "Applies the i-th PastDecomposableMixing block.", "input": "enc_out_list (list of Tensors)", "output": "list of Tensors", "location_or_namespace": "TimeMixer/models/TimeMixer.py" }, { "function_call_name": "self.projection_layer", "functionality": "Applies a linear projection to the input tensor.", "input": "enc_out_list[0] (Tensor)", "output": "Tensor", "location_or_namespace": "TimeMixer/models/TimeMixer.py" }, { "function_call_name": "dec_out.reshape", "functionality": "Returns a tensor with the same data and number of elements as self but with the specified shape.", "input": "B (int), self.configs.c_out (int), -1 (int)", "output": "Tensor", "location_or_namespace": "torch.Tensor" }, { "function_call_name": "dec_out.permute", "functionality": "Permutes the dimensions of the tensor.", "input": "0, 2, 1 (int, int, int)", "output": "Tensor", "location_or_namespace": "torch.Tensor" }, { "function_call_name": "dec_out.contiguous", "functionality": "Returns a contiguous in memory tensor containing the same data as self tensor.", "input": "", "output": "Tensor", "location_or_namespace": "torch.Tensor" }, { "function_call_name": "self.normalize_layers[0]", "functionality": "Applies denormalization to the output tensor.", "input": "dec_out (Tensor), 'denorm' (str)", "output": "Tensor", "location_or_namespace": "TimeMixer/models/TimeMixer.py or layers.StandardNorm" } ] }, { "function_name": "Model.imputation", "file_path": "models/TimeMixer.py", "function_calls": [ { "function_call_name": "torch.sum", "functionality": "Returns the sum of all elements in the input tensor.", "input": "x_enc (Tensor), dim=1 (int) or mask == 1 (Tensor), dim=1 (int) or x_enc * x_enc (Tensor), dim=1 (int)", "output": "Tensor", "location_or_namespace": "torch" }, { "function_call_name": "means.unsqueeze", "functionality": "Returns a new tensor with a dimension of size one inserted at the specified position.", "input": "1 (int)", "output": "Tensor", "location_or_namespace": "torch.Tensor" }, { "function_call_name": "means.detach", "functionality": "Returns a new Tensor, detached from the current graph.", "input": "", "output": "Tensor", "location_or_namespace": "torch.Tensor" }, { "function_call_name": "x_enc.masked_fill", "functionality": "Fills elements of self tensor with value where mask is True.", "input": "mask == 0 (Tensor), 0 (int)", "output": "Tensor", "location_or_namespace": "torch.Tensor" }, { "function_call_name": "torch.sqrt", "functionality": "Returns a new tensor with the square-root of the elements of input.", "input": "torch.sum(...) / torch.sum(...) + 1e-5 (Tensor)", "output": "Tensor", "location_or_namespace": "torch" }, { "function_call_name": "stdev.unsqueeze", "functionality": "Returns a new tensor with a dimension of size one inserted at the specified position.", "input": "1 (int)", "output": "Tensor", "location_or_namespace": "torch.Tensor" }, { "function_call_name": "stdev.detach", "functionality": "Returns a new Tensor, detached from the current graph.", "input": "", "output": "Tensor", "location_or_namespace": "torch.Tensor" }, { "function_call_name": "x_enc.size", "functionality": "Returns the size of the self tensor.", "input": "", "output": "torch.Size", "location_or_namespace": "torch.Tensor" }, { "function_call_name": "self.__multi_scale_process_inputs", "functionality": "Processes input tensors to create multi-scale versions.", "input": "x_enc (Tensor), x_mark_enc (Tensor)", "output": "tuple (x_enc_list (list of Tensors), x_mark_enc_list (list of Tensors or None))", "location_or_namespace": "TimeMixer/models/TimeMixer.py" }, { "function_call_name": "zip", "functionality": "Returns an iterator of tuples, where the i-th tuple contains the i-th element from each of the argument sequences or iterables.", "input": "range(len(x_enc)), x_enc, x_mark_enc or range(len(x_enc)), x_enc", "output": "iterator", "location_or_namespace": "builtins" }, { "function_call_name": "range", "functionality": "Generates a sequence of numbers.", "input": "len(x_enc) (int) or self.layer (int)", "output": "iterator", "location_or_namespace": "builtins" }, { "function_call_name": "len", "functionality": "Returns the length of an object.", "input": "x_enc (list)", "output": "int", "location_or_namespace": "builtins" }, { "function_call_name": "x.permute", "functionality": "Permutes the dimensions of the tensor.", "input": "0, 2, 1 (int, int, int)", "output": "Tensor", "location_or_namespace": "torch.Tensor" }, { "function_call_name": "x.contiguous", "functionality": "Returns a contiguous in memory tensor containing the same data as self tensor.", "input": "", "output": "Tensor", "location_or_namespace": "torch.Tensor" }, { "function_call_name": "x.reshape", "functionality": "Returns a tensor with the same data and number of elements as self but with the specified shape.", "input": "B * N (int), T (int), 1 (int)", "output": "Tensor", "location_or_namespace": "torch.Tensor" }, { "function_call_name": "x_list.append", "functionality": "Appends an element to the list.", "input": "x (Tensor)", "output": "None", "location_or_namespace": "builtins.list" }, { "function_call_name": "x_mark.repeat", "functionality": "Repeats this tensor along the specified dimensions.", "input": "N (int), 1 (int), 1 (int)", "output": "Tensor", "location_or_namespace": "torch.Tensor" }, { "function_call_name": "x_mark_list.append", "functionality": "Appends an element to the list.", "input": "x_mark (Tensor)", "output": "None", "location_or_namespace": "builtins.list" }, { "function_call_name": "self.enc_embedding", "functionality": "Embeds the input tensor.", "input": "x (Tensor), None", "output": "Tensor", "location_or_namespace": "TimeMixer/models/TimeMixer.py or layers.Embed" }, { "function_call_name": "enc_out_list.append", "functionality": "Appends an element to the list.", "input": "enc_out (Tensor)", "output": "None", "location_or_namespace": "builtins.list" }, { "function_call_name": "self.pdm_blocks[i]", "functionality": "Applies the i-th PastDecomposableMixing block.", "input": "enc_out_list (list of Tensors)", "output": "list of Tensors", "location_or_namespace": "TimeMixer/models/TimeMixer.py" }, { "function_call_name": "self.projection_layer", "functionality": "Applies a linear projection to the input tensor.", "input": "enc_out_list[0] (Tensor)", "output": "Tensor", "location_or_namespace": "TimeMixer/models/TimeMixer.py" }, { "function_call_name": "dec_out.reshape", "functionality": "Returns a tensor with the same data and number of elements as self but with the specified shape.", "input": "B (int), self.configs.c_out (int), -1 (int)", "output": "Tensor", "location_or_namespace": "torch.Tensor" }, { "function_call_name": "dec_out.permute", "functionality": "Permutes the dimensions of the tensor.", "input": "0, 2, 1 (int, int, int)", "output": "Tensor", "location_or_namespace": "torch.Tensor" }, { "function_call_name": "dec_out.contiguous", "functionality": "Returns a contiguous in memory tensor containing the same data as self tensor.", "input": "", "output": "Tensor", "location_or_namespace": "torch.Tensor" }, { "function_call_name": "stdev[:, 0, :].unsqueeze", "functionality": "Returns a new tensor with a dimension of size one inserted at the specified position.", "input": "1 (int)", "output": "Tensor", "location_or_namespace": "torch.Tensor" }, { "function_call_name": "torch.Tensor.repeat", "functionality": "Repeats this tensor along the specified dimensions.", "input": "1 (int), self.seq_len (int), 1 (int)", "output": "Tensor", "location_or_namespace": "torch.Tensor" }, { "function_call_name": "means[:, 0, :].unsqueeze", "functionality": "Returns a new tensor with a dimension of size one inserted at the specified position.", "input": "1 (int)", "output": "Tensor", "location_or_namespace": "torch.Tensor" } ] }, { "function_name": "Model.forward", "file_path": "models/TimeMixer.py", "function_calls": [ { "function_call_name": "self.forecast", "functionality": "Performs time series forecasting.", "input": "x_enc (Tensor), x_mark_enc (Tensor), x_dec (Tensor), x_mark_dec (Tensor)", "output": "Tensor", "location_or_namespace": "TimeMixer/models/TimeMixer.py" }, { "function_call_name": "self.imputation", "functionality": "Performs time series imputation.", "input": "x_enc (Tensor), x_mark_enc (Tensor), mask (Tensor)", "output": "Tensor", "location_or_namespace": "TimeMixer/models/TimeMixer.py" }, { "function_call_name": "self.anomaly_detection", "functionality": "Performs time series anomaly detection.", "input": "x_enc (Tensor)", "output": "Tensor", "location_or_namespace": "TimeMixer/models/TimeMixer.py" }, { "function_call_name": "self.classification", "functionality": "Performs time series classification.", "input": "x_enc (Tensor), x_mark_enc (Tensor)", "output": "Tensor", "location_or_namespace": "TimeMixer/models/TimeMixer.py" }, { "function_call_name": "ValueError", "functionality": "Raises a ValueError exception.", "input": "'Other tasks implemented yet' (str)", "output": "None", "location_or_namespace": "builtins" } ] } ]
[
{
"function_name": "DFT_series_decomp.__init__",
"file_path": "models/TimeMixer.py",
"function_calls": [
{
"function_call_name": "super",
"functionality": "Initializes the parent class (nn.Module).",
"input": "",
"output": "DFT_series_decomp object",
"location_or_namespace": "builtins"
}
]
},
{
"function_name": "DFT_series_decomp.forward",
"file_path": "models/TimeMixer.py",
"function_calls": [
{
"function_call_name": "torch.fft.rfft",
"functionality": "Computes the one-dimensional discrete Fourier Transform for real input.",
"input": "x (Tensor)",
"output": "Tensor",
"location_or_namespace": "torch.fft"
},
{
"function_call_name": "abs",
"functionality": "Computes the absolute value of each element in the input tensor.",
"input": "xf (Tensor)",
"output": "Tensor",
"location_or_namespace": "builtins"
},
{
"function_call_name": "torch.topk",
"functionality": "Returns the k largest elements of the given input tensor along a given dimension.",
"input": "freq (Tensor), 5 (int)",
"output": "tuple (top_k_freq (Tensor), top_list (Tensor))",
"location_or_namespace": "torch"
},
{
"function_call_name": "top_k_freq.min",
"functionality": "Returns the minimum value of all elements in the input tensor.",
"input": "",
"output": "Tensor",
"location_or_namespace": "torch.Tensor"
},
{
"function_call_name": "torch.fft.irfft",
"functionality": "Computes the one-dimensional inverse discrete Fourier Transform for real output.",
"input": "xf (Tensor)",
"output": "Tensor",
"location_or_namespace": "torch.fft"
}
]
},
{
"function_name": "MultiScaleSeasonMixing.__init__",
"file_path": "models/TimeMixer.py",
"function_calls": [
{
"function_call_name": "super",
"functionality": "Initializes the parent class (nn.Module).",
"input": "",
"output": "MultiScaleSeasonMixing object",
"location_or_namespace": "builtins"
},
{
"function_call_name": "torch.nn.ModuleList",
"functionality": "Holds submodules in a list.",
"input": "[nn.Sequential(...)]",
"output": "ModuleList object",
"location_or_namespace": "torch.nn"
},
{
"function_call_name": "torch.nn.Sequential",
"functionality": "A sequential container of modules.",
"input": "torch.nn.Linear, nn.GELU, torch.nn.Linear",
"output": "Sequential object",
"location_or_namespace": "torch.nn"
},
{
"function_call_name": "torch.nn.Linear",
"functionality": "Applies a linear transformation to the incoming data.",
"input": "in_features (int), out_features (int)",
"output": "Linear object",
"location_or_namespace": "torch.nn"
},
{
"function_call_name": "torch.nn.GELU",
"functionality": "Applies the Gaussian Error Linear Unit function element-wise.",
"input": "",
"output": "GELU object",
"location_or_namespace": "torch.nn"
},
{
"function_call_name": "range",
"functionality": "Generates a sequence of numbers.",
"input": "configs.down_sampling_layers (int)",
"output": "iterator",
"location_or_namespace": "builtins"