{
  "__type": "IngestedDoc",
  "__tag": 4010,
  "_content": {
    "Notes": {
      "__type": "Section",
      "__tag": 4015,
      "children": [],
      "title": [],
      "level": 0,
      "target": null
    },
    "Warns": {
      "__type": "Section",
      "__tag": 4015,
      "children": [],
      "title": [],
      "level": 0,
      "target": null
    },
    "Raises": {
      "__type": "Section",
      "__tag": 4015,
      "children": [],
      "title": [],
      "level": 0,
      "target": null
    },
    "Yields": {
      "__type": "Section",
      "__tag": 4015,
      "children": [],
      "title": [],
      "level": 0,
      "target": null
    },
    "Methods": {
      "__type": "Section",
      "__tag": 4015,
      "children": [],
      "title": [],
      "level": 0,
      "target": null
    },
    "Returns": {
      "__type": "Section",
      "__tag": 4015,
      "children": [
        {
          "__type": "Parameters",
          "__tag": 4026,
          "children": [
            {
              "__type": "DocParam",
              "__tag": 4016,
              "name": "footprint",
              "annotation": "array or tuple[tuple[ndarray, int], ...]",
              "desc": [
                {
                  "__type": "Paragraph",
                  "__tag": 4045,
                  "children": [
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": "A footprint consisting only of ones, i.e. every pixel belongs to the neighborhood. When "
                    },
                    {
                      "__type": "ParamRef",
                      "__tag": 4071,
                      "name": "decomposition"
                    },
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": " is None, this is just an array. Otherwise, this will be a tuple whose length is equal to the number of unique structuring elements to apply (see Examples for more detail)."
                    }
                  ]
                }
              ]
            }
          ]
        }
      ],
      "title": [],
      "level": 0,
      "target": null
    },
    "Summary": {
      "__type": "Section",
      "__tag": 4015,
      "children": [
        {
          "__type": "Paragraph",
          "__tag": 4045,
          "children": [
            {
              "__type": "Text",
              "__tag": 4046,
              "value": "Generate a rectangular or hyper-rectangular footprint."
            }
          ]
        }
      ],
      "title": [],
      "level": 0,
      "target": null
    },
    "Receives": {
      "__type": "Section",
      "__tag": 4015,
      "children": [],
      "title": [],
      "level": 0,
      "target": null
    },
    "Warnings": {
      "__type": "Section",
      "__tag": 4015,
      "children": [],
      "title": [],
      "level": 0,
      "target": null
    },
    "Attributes": {
      "__type": "Section",
      "__tag": 4015,
      "children": [],
      "title": [],
      "level": 0,
      "target": null
    },
    "Parameters": {
      "__type": "Section",
      "__tag": 4015,
      "children": [
        {
          "__type": "Parameters",
          "__tag": 4026,
          "children": [
            {
              "__type": "DocParam",
              "__tag": 4016,
              "name": "shape",
              "annotation": "tuple[int, ...]",
              "desc": [
                {
                  "__type": "Paragraph",
                  "__tag": 4045,
                  "children": [
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": "The length of the footprint in each dimension. The length of the sequence determines the number of dimensions of the footprint."
                    }
                  ]
                }
              ]
            },
            {
              "__type": "DocParam",
              "__tag": 4016,
              "name": "dtype",
              "annotation": "dtype-like, optional",
              "desc": [
                {
                  "__type": "Paragraph",
                  "__tag": 4045,
                  "children": [
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": "The data type of the footprint."
                    }
                  ]
                }
              ]
            },
            {
              "__type": "DocParam",
              "__tag": 4016,
              "name": "decomposition",
              "annotation": "{None, 'separable', 'sequence'}, optional",
              "desc": [
                {
                  "__type": "Paragraph",
                  "__tag": 4045,
                  "children": [
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": "If None, a single array is returned. For 'sequence', a tuple of smaller footprints is returned. Applying this series of smaller footprints will give an identical result to a single, larger footprint, but often with better computational performance. See Notes for more details. With 'separable', this function uses separable 1D footprints for each axis. Whether 'sequence' or 'separable' is computationally faster may be architecture-dependent."
                    }
                  ]
                }
              ]
            }
          ]
        }
      ],
      "title": [],
      "level": 0,
      "target": null
    },
    "Extended Summary": {
      "__type": "Section",
      "__tag": 4015,
      "children": [
        {
          "__type": "Paragraph",
          "__tag": 4045,
          "children": [
            {
              "__type": "Text",
              "__tag": 4046,
              "value": "Generates, depending on the length and dimensions requested with "
            },
            {
              "__type": "ParamRef",
              "__tag": 4071,
              "name": "shape"
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": ", a square, rectangle, cube, cuboid, or even higher-dimensional versions of these shapes."
            }
          ]
        }
      ],
      "title": [],
      "level": 0,
      "target": null
    },
    "Other Parameters": {
      "__type": "Section",
      "__tag": 4015,
      "children": [],
      "title": [],
      "level": 0,
      "target": null
    }
  },
  "_ordered_sections": [
    "Summary",
    "Extended Summary",
    "Parameters",
    "Returns",
    "Yields",
    "Receives",
    "Raises",
    "Warns",
    "Other Parameters",
    "Attributes",
    "Methods",
    "Notes",
    "Warnings"
  ],
  "item_file": "/dev/scikit-image/src/skimage/morphology/footprints.py",
  "item_line": 81,
  "item_type": "function",
  "aliases": [
    "skimage.morphology.footprint_rectangle"
  ],
  "example_section_data": {
    "__type": "Section",
    "__tag": 4015,
    "children": [
      {
        "__type": "Code",
        "__tag": 4050,
        "value": "import skimage as ski\nski.morphology.footprint_rectangle((3, 5))\n",
        "execution_status": "success"
      },
      {
        "__type": "Text",
        "__tag": 4046,
        "value": "\nDecomposition will return multiple footprints that combine into a simple\nfootprint of the requested shape.\n\n"
      },
      {
        "__type": "Code",
        "__tag": 4050,
        "value": "ski.morphology.footprint_rectangle((9, 9), decomposition=\"sequence\")\n",
        "execution_status": "failure"
      },
      {
        "__type": "Text",
        "__tag": 4046,
        "value": "\n`\"sequence\"` makes sure that the decomposition only returns 1D footprints.\n\n"
      },
      {
        "__type": "Code",
        "__tag": 4050,
        "value": "ski.morphology.footprint_rectangle((3, 5), decomposition=\"separable\")\n",
        "execution_status": "failure"
      },
      {
        "__type": "Text",
        "__tag": 4046,
        "value": "\nGenerate a 5-dimensional hypercube with 3 samples in each dimension\n\n"
      },
      {
        "__type": "Code",
        "__tag": 4050,
        "value": "ski.morphology.footprint_rectangle((3,) * 5).shape\n",
        "execution_status": "success"
      }
    ],
    "title": [],
    "level": 0,
    "target": null
  },
  "see_also": [],
  "signature": {
    "__type": "SignatureNode",
    "__tag": 4029,
    "kind": "function",
    "parameters": [
      {
        "__type": "SigParam",
        "__tag": 4030,
        "name": "shape",
        "annotation": {
          "__type": "Empty",
          "__tag": 4031
        },
        "kind": "POSITIONAL_OR_KEYWORD",
        "default": {
          "__type": "Empty",
          "__tag": 4031
        }
      },
      {
        "__type": "SigParam",
        "__tag": 4030,
        "name": "dtype",
        "annotation": {
          "__type": "Empty",
          "__tag": 4031
        },
        "kind": "KEYWORD_ONLY",
        "default": "<class 'numpy.uint8'>"
      },
      {
        "__type": "SigParam",
        "__tag": 4030,
        "name": "decomposition",
        "annotation": {
          "__type": "Empty",
          "__tag": 4031
        },
        "kind": "KEYWORD_ONLY",
        "default": "None"
      }
    ],
    "return_annotation": {
      "__type": "Empty",
      "__tag": 4031
    },
    "target_name": "footprint_rectangle"
  },
  "references": null,
  "qa": "skimage.morphology.footprints:footprint_rectangle",
  "arbitrary": [],
  "local_refs": [
    "decomposition",
    "dtype",
    "footprint",
    "shape"
  ]
}