code: def test_pipenet_return_list_return_intermediate():
      """
      Test pipenet with return_list=True and return_intermediate=True
      """
      df = pd.DataFrame(
          np.array(
              [
                  [0, 1, 2, 3, 4, 5, 6, 7, 8, 9],
                  [0, 10, 20, 30, 41, 50, 60, 70, 80, 90],
                  [0, 100, 200, 300, 400, 500, 601, 700, 800, 900],
                  [0, 0, 0, 0, 0, 0, 0, 100, 0, 0],
              ]
          ).T,
          index=pd.date_range(start="2017-1-1", periods=10, freq="D"),
          columns=["A", "B", "C", "D"],
      )
  
      reg_ab = LinearRegression()
      reg_ac = LinearRegression()
      my_pipe = Pipenet(
          {
              "A-B-regression-ad": {
                  "model": detector.RegressionAD(
                      regressor=reg_ab, target="B"
                  ),
                  "input": "original",
                  "subset": ["A", "B"],
              },
              "A-C-regression-error": {
                  "model": transformer.RegressionResidual(
                      regressor=reg_ac, target="C"
                  ),
                  "input": "original",
                  "subset": ["A", "C"],
              },
              "A-C-regression-ad": {
                  "model": detector.InterQuartileRangeAD(),
                  "input": "A-C-regression-error",
                  "subset": "all",
              },
              "ABC-ad": {
                  "model": aggregator.OrAggregator(),
                  "input": ["A-B-regression-ad", "A-C-regression-ad"],
              },
              "D-ad": {
                  "model": detector.QuantileAD(high=0.9, low=0.1),
                  "input": "original",
                  "subset": ["D"],
              },
              "ABCD-ad": {
                  "model": aggregator.OrAggregator(),
                  "input": ["ABC-ad", "D-ad"],
              },
          }
      )
  
      results = my_pipe.fit_detect(
          df, return_list=True, return_intermediate=True
      )
      assert set(results.keys()) == set(my_pipe.steps.keys()).union(
          {"original"}
      )
      assert results["A-B-regression-ad"] == [
          (
              pd.Timestamp("2017-01-05 00:00:00"),
              pd.Timestamp("2017-01-05 23:59:59.999999999"),
          )
      ]
      assert results["A-C-regression-ad"] == [
          (
              pd.Timestamp("2017-01-07 00:00:00"),
              pd.Timestamp("2017-01-07 23:59:59.999999999"),
          )
      ]
      assert results["ABC-ad"] == [
          (
              pd.Timestamp("2017-01-05 00:00:00"),
              pd.Timestamp("2017-01-05 23:59:59.999999999"),
          ),
          (
              pd.Timestamp("2017-01-07 00:00:00"),
              pd.Timestamp("2017-01-07 23:59:59.999999999"),
          ),
      ]
      assert results["D-ad"] == [
          (
              pd.Timestamp("2017-01-08 00:00:00"),
              pd.Timestamp("2017-01-08 23:59:59.999999999"),
          )
      ]
      assert results["ABCD-ad"] == [
          (
              pd.Timestamp("2017-01-05 00:00:00"),
              pd.Timestamp("2017-01-05 23:59:59.999999999"),
          ),
          (
              pd.Timestamp("2017-01-07 00:00:00"),
              pd.Timestamp("2017-01-08 23:59:59.999999999"),
          ),
      ]
  
file_path: adtk/tests/test_pipe.py
imports: import numpy
  import pandas
  import pytest
  from sklearn.linear_model import LinearRegression
  import adtk.aggregator
  import adtk.detector
  import adtk.transformer
  from adtk.pipe import Pipeline, Pipenet
label_desc: Use image node_id 4 for calling a global function with example usage: test_pipenet_return_list_return_intermediate() without return types