We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
HTTP internal server error when trying to download ``AbovegroundLiveWoodyBiomassDensity``
### Description

There is an ``urllib.error.HTTPError: HTTP Error 500: Internal Server Error`` occuring . This issue occures when compiling from github and installing using pip3. It is occuring for`` AbovegroundLiveWoodyBiomassDensity`` which is a module from ``torchgeo.datasets.agb_live_woody_density``

### Steps to reproduce

python
``
from torchgeo.datasets.agb_live_woody_density import AbovegroundLiveWoodyBiomassDensity 
ALWBD = AbovegroundLiveWoodyBiomassDensity(paths="~/test", download=True)
``


### Version

0.6.0.dev0 and 0.5.0

--- END ISSUE ---

Below are some code segments, each from a relevant file. One or more of these files may contain bugs.
--- BEGIN FILES ---
Path: `torchgeo/datasets/agb_live_woody_density.py`
Content:
```
1 # Copyright (c) Microsoft Corporation. All rights reserved.
2 # Licensed under the MIT License.
3 
4 """Aboveground Live Woody Biomass Density dataset."""
5 
6 import json
7 import os
8 from collections.abc import Iterable
9 from typing import Any, Callable, Optional, Union
10 
11 import matplotlib.pyplot as plt
12 from matplotlib.figure import Figure
13 from rasterio.crs import CRS
14 
15 from .geo import RasterDataset
16 from .utils import download_url
17 
18 
19 class AbovegroundLiveWoodyBiomassDensity(RasterDataset):
20     """Aboveground Live Woody Biomass Density dataset.
21 
22     The `Aboveground Live Woody Biomass Density dataset
23     <https://data.globalforestwatch.org/datasets/gfw::aboveground-live-woody
24     -biomass-density/about>`_
25     is a global-scale, wall-to-wall map of aboveground biomass at ~30m resolution
26     for the year 2000.
27 
28     Dataset features:
29 
30     * Masks with per pixel live woody biomass density estimates in megagrams
31       biomass per hectare at ~30m resolution (~40,000x40,0000 px)
32 
33     Dataset format:
34 
35     * geojson file that contains download links to tif files
36     * single-channel geotiffs with the pixel values representing biomass density
37 
38     If you use this dataset in your research, please give credit to:
39 
40     * `Global Forest Watch <https://data.globalforestwatch.org/>`_
41 
42     .. versionadded:: 0.3
43     """
44 
45     is_image = False
46 
47     url = (
48         "https://opendata.arcgis.com/api/v3/datasets/3e8736c8866b458687"
49         "e00d40c9f00bce_0/downloads/data?format=geojson&spatialRefId=4326"
50     )
51 
52     base_filename = "Aboveground_Live_Woody_Biomass_Density.geojson"
53 
54     filename_glob = "*N_*E.*"
55     filename_regex = r"""^
56         (?P<latitude>[0-9][0-9][A-Z])_
57         (?P<longitude>[0-9][0-9][0-9][A-Z])*
58     """
59 
60     def __init__(
61         self,
62         paths: Union[str, Iterable[str]] = "data",
63         crs: Optional[CRS] = None,
64         res: Optional[float] = None,
65         transforms: Optional[Callable[[dict[str, Any]], dict[str, Any]]] = None,
66         download: bool = False,
67         cache: bool = True,
68     ) -> None:
69         """Initialize a new Dataset instance.
70 
71         Args:
72             paths: one or more root directories to search or files to load
73             crs: :term:`coordinate reference system (CRS)` to warp to
74                 (defaults to the CRS of the first file found)
75             res: resolution of the dataset in units of CRS
76                 (defaults to the resolution of the first file found)
77             transforms: a function/transform that takes an input sample
78                 and returns a transformed version
79             download: if True, download dataset and store it in the root directory
80             cache: if True, cache file handle to speed up repeated sampling
81 
82         Raises:
83             FileNotFoundError: if no files are found in ``paths``
84 
85         .. versionchanged:: 0.5
86            *root* was renamed to *paths*.
87         """
88         self.paths = paths
89         self.download = download
90 
91         self._verify()
92 
93         super().__init__(paths, crs, res, transforms=transforms, cache=cache)
94 
95     def _verify(self) -> None:
96         """Verify the integrity of the dataset.
97 
98         Raises:
99             RuntimeError: if dataset is missing
100         """
101         # Check if the extracted files already exist
102         if self.files:
103             return
104 
105         # Check if the user requested to download the dataset
106         if not self.download:
107             raise RuntimeError(
108                 f"Dataset not found in `paths={self.paths!r}` and `download=False`, "
109                 "either specify a different `root` directory or use `download=True` "
110                 "to automatically download the dataset."
111             )
112 
113         # Download the dataset
114         self._download()
115 
116     def _download(self) -> None:
117         """Download the dataset."""
118         assert isinstance(self.paths, str)
119         download_url(self.url, self.paths, self.base_filename)
120 
121         with open(os.path.join(self.paths, self.base_filename)) as f:
122             content = json.load(f)
123 
124         for item in content["features"]:
125             download_url(
126                 item["properties"]["download"],
127                 self.paths,
128                 item["properties"]["tile_id"] + ".tif",
129             )
130 
131     def plot(
132         self,
133         sample: dict[str, Any],
134         show_titles: bool = True,
135         suptitle: Optional[str] = None,
136     ) -> Figure:
137         """Plot a sample from the dataset.
138 
139         Args:
140             sample: a sample returned by :meth:`RasterDataset.__getitem__`
141             show_titles: flag indicating whether to show titles above each panel
142             suptitle: optional string to use as a suptitle
143 
144         Returns:
145             a matplotlib Figure with the rendered sample
146         """
147         mask = sample["mask"].squeeze()
148         ncols = 1
149 
150         showing_predictions = "prediction" in sample
151         if showing_predictions:
152             pred = sample["prediction"].squeeze()
153             ncols = 2
154 
155         fig, axs = plt.subplots(nrows=1, ncols=ncols, figsize=(ncols * 4, 4))
156 
157         if showing_predictions:
158             axs[0].imshow(mask)
159             axs[0].axis("off")
160             axs[1].imshow(pred)
161             axs[1].axis("off")
162             if show_titles:
163                 axs[0].set_title("Mask")
164                 axs[1].set_title("Prediction")
165         else:
166             axs.imshow(mask)
167             axs.axis("off")
168             if show_titles:
169                 axs.set_title("Mask")
170 
171         if suptitle is not None:
172             plt.suptitle(suptitle)
173 
174         return fig
175
```
--- END FILES ---

Please first localize the bug based on the issue statement, and then generate a patch according to the `git diff` format fenced by three backticks.

Here is an example:

```diff
diff --git a/examples/server_async.py b/examples/server_async.py
--- a/examples/server_async.py
+++ b/examples/server_async.py
@@ -313,4 +313,4 @@
 
 
 if __name__ == "__main__":
-    asyncio.run(run_async_server("."), debug=True)
+    asyncio.run(run_async_server(), debug=True)
diff --git a/examples/server_sync.py b/examples/server_sync.py
--- a/examples/server_sync.py
+++ b/examples/server_sync.py
@@ -313,5 +313,5 @@
 
 
 if __name__ == "__main__":
-    server = run_sync_server(".")
+    server = run_sync_server()
     server.shutdown()

```

diff --git a/torchgeo/datasets/agb_live_woody_density.py b/torchgeo/datasets/agb_live_woody_density.py
--- a/torchgeo/datasets/agb_live_woody_density.py
+++ b/torchgeo/datasets/agb_live_woody_density.py
@@ -44,10 +44,7 @@
 
     is_image = False
 
-    url = (
-        "https://opendata.arcgis.com/api/v3/datasets/3e8736c8866b458687"
-        "e00d40c9f00bce_0/downloads/data?format=geojson&spatialRefId=4326"
-    )
+    url = "https://opendata.arcgis.com/api/v3/datasets/e4bdbe8d6d8d4e32ace7d36a4aec7b93_0/downloads/data?format=geojson&spatialRefId=4326"  # noqa: E501
 
     base_filename = "Aboveground_Live_Woody_Biomass_Density.geojson"
 
@@ -123,7 +120,7 @@
 
         for item in content["features"]:
             download_url(
-                item["properties"]["download"],
+                item["properties"]["Mg_px_1_download"],
                 self.paths,
                 item["properties"]["tile_id"] + ".tif",
             )

{"golden_diff": "diff --git a/torchgeo/datasets/agb_live_woody_density.py b/torchgeo/datasets/agb_live_woody_density.py\n--- a/torchgeo/datasets/agb_live_woody_density.py\n+++ b/torchgeo/datasets/agb_live_woody_density.py\n@@ -44,10 +44,7 @@\n \n     is_image = False\n \n-    url = (\n-        \"https://opendata.arcgis.com/api/v3/datasets/3e8736c8866b458687\"\n-        \"e00d40c9f00bce_0/downloads/data?format=geojson&spatialRefId=4326\"\n-    )\n+    url = \"https://opendata.arcgis.com/api/v3/datasets/e4bdbe8d6d8d4e32ace7d36a4aec7b93_0/downloads/data?format=geojson&spatialRefId=4326\"  # noqa: E501\n \n     base_filename = \"Aboveground_Live_Woody_Biomass_Density.geojson\"\n \n@@ -123,7 +120,7 @@\n \n         for item in content[\"features\"]:\n             download_url(\n-                item[\"properties\"][\"download\"],\n+                item[\"properties\"][\"Mg_px_1_download\"],\n                 self.paths,\n                 item[\"properties\"][\"tile_id\"] + \".tif\",\n             )\n", "issue": "HTTP internal server error when trying to download ``AbovegroundLiveWoodyBiomassDensity``\n### Description\n\nThere is an ``urllib.error.HTTPError: HTTP Error 500: Internal Server Error`` occuring . This issue occures when compiling from github and installing using pip3. It is occuring for`` AbovegroundLiveWoodyBiomassDensity`` which is a module from ``torchgeo.datasets.agb_live_woody_density``\n\n### Steps to reproduce\n\npython\r\n``\r\nfrom torchgeo.datasets.agb_live_woody_density import AbovegroundLiveWoodyBiomassDensity \r\nALWBD = AbovegroundLiveWoodyBiomassDensity(paths=\"~/test\", download=True)\r\n``\r\n\n\n### Version\n\n0.6.0.dev0 and 0.5.0\n", "before_files": [{"content": "# Copyright (c) Microsoft Corporation. All rights reserved.\n# Licensed under the MIT License.\n\n\"\"\"Aboveground Live Woody Biomass Density dataset.\"\"\"\n\nimport json\nimport os\nfrom collections.abc import Iterable\nfrom typing import Any, Callable, Optional, Union\n\nimport matplotlib.pyplot as plt\nfrom matplotlib.figure import Figure\nfrom rasterio.crs import CRS\n\nfrom .geo import RasterDataset\nfrom .utils import download_url\n\n\nclass AbovegroundLiveWoodyBiomassDensity(RasterDataset):\n    \"\"\"Aboveground Live Woody Biomass Density dataset.\n\n    The `Aboveground Live Woody Biomass Density dataset\n    <https://data.globalforestwatch.org/datasets/gfw::aboveground-live-woody\n    -biomass-density/about>`_\n    is a global-scale, wall-to-wall map of aboveground biomass at ~30m resolution\n    for the year 2000.\n\n    Dataset features:\n\n    * Masks with per pixel live woody biomass density estimates in megagrams\n      biomass per hectare at ~30m resolution (~40,000x40,0000 px)\n\n    Dataset format:\n\n    * geojson file that contains download links to tif files\n    * single-channel geotiffs with the pixel values representing biomass density\n\n    If you use this dataset in your research, please give credit to:\n\n    * `Global Forest Watch <https://data.globalforestwatch.org/>`_\n\n    .. versionadded:: 0.3\n    \"\"\"\n\n    is_image = False\n\n    url = (\n        \"https://opendata.arcgis.com/api/v3/datasets/3e8736c8866b458687\"\n        \"e00d40c9f00bce_0/downloads/data?format=geojson&spatialRefId=4326\"\n    )\n\n    base_filename = \"Aboveground_Live_Woody_Biomass_Density.geojson\"\n\n    filename_glob = \"*N_*E.*\"\n    filename_regex = r\"\"\"^\n        (?P<latitude>[0-9][0-9][A-Z])_\n        (?P<longitude>[0-9][0-9][0-9][A-Z])*\n    \"\"\"\n\n    def __init__(\n        self,\n        paths: Union[str, Iterable[str]] = \"data\",\n        crs: Optional[CRS] = None,\n        res: Optional[float] = None,\n        transforms: Optional[Callable[[dict[str, Any]], dict[str, Any]]] = None,\n        download: bool = False,\n        cache: bool = True,\n    ) -> None:\n        \"\"\"Initialize a new Dataset instance.\n\n        Args:\n            paths: one or more root directories to search or files to load\n            crs: :term:`coordinate reference system (CRS)` to warp to\n                (defaults to the CRS of the first file found)\n            res: resolution of the dataset in units of CRS\n                (defaults to the resolution of the first file found)\n            transforms: a function/transform that takes an input sample\n                and returns a transformed version\n            download: if True, download dataset and store it in the root directory\n            cache: if True, cache file handle to speed up repeated sampling\n\n        Raises:\n            FileNotFoundError: if no files are found in ``paths``\n\n        .. versionchanged:: 0.5\n           *root* was renamed to *paths*.\n        \"\"\"\n        self.paths = paths\n        self.download = download\n\n        self._verify()\n\n        super().__init__(paths, crs, res, transforms=transforms, cache=cache)\n\n    def _verify(self) -> None:\n        \"\"\"Verify the integrity of the dataset.\n\n        Raises:\n            RuntimeError: if dataset is missing\n        \"\"\"\n        # Check if the extracted files already exist\n        if self.files:\n            return\n\n        # Check if the user requested to download the dataset\n        if not self.download:\n            raise RuntimeError(\n                f\"Dataset not found in `paths={self.paths!r}` and `download=False`, \"\n                \"either specify a different `root` directory or use `download=True` \"\n                \"to automatically download the dataset.\"\n            )\n\n        # Download the dataset\n        self._download()\n\n    def _download(self) -> None:\n        \"\"\"Download the dataset.\"\"\"\n        assert isinstance(self.paths, str)\n        download_url(self.url, self.paths, self.base_filename)\n\n        with open(os.path.join(self.paths, self.base_filename)) as f:\n            content = json.load(f)\n\n        for item in content[\"features\"]:\n            download_url(\n                item[\"properties\"][\"download\"],\n                self.paths,\n                item[\"properties\"][\"tile_id\"] + \".tif\",\n            )\n\n    def plot(\n        self,\n        sample: dict[str, Any],\n        show_titles: bool = True,\n        suptitle: Optional[str] = None,\n    ) -> Figure:\n        \"\"\"Plot a sample from the dataset.\n\n        Args:\n            sample: a sample returned by :meth:`RasterDataset.__getitem__`\n            show_titles: flag indicating whether to show titles above each panel\n            suptitle: optional string to use as a suptitle\n\n        Returns:\n            a matplotlib Figure with the rendered sample\n        \"\"\"\n        mask = sample[\"mask\"].squeeze()\n        ncols = 1\n\n        showing_predictions = \"prediction\" in sample\n        if showing_predictions:\n            pred = sample[\"prediction\"].squeeze()\n            ncols = 2\n\n        fig, axs = plt.subplots(nrows=1, ncols=ncols, figsize=(ncols * 4, 4))\n\n        if showing_predictions:\n            axs[0].imshow(mask)\n            axs[0].axis(\"off\")\n            axs[1].imshow(pred)\n            axs[1].axis(\"off\")\n            if show_titles:\n                axs[0].set_title(\"Mask\")\n                axs[1].set_title(\"Prediction\")\n        else:\n            axs.imshow(mask)\n            axs.axis(\"off\")\n            if show_titles:\n                axs.set_title(\"Mask\")\n\n        if suptitle is not None:\n            plt.suptitle(suptitle)\n\n        return fig\n", "path": "torchgeo/datasets/agb_live_woody_density.py"}], "after_files": [{"content": "# Copyright (c) Microsoft Corporation. All rights reserved.\n# Licensed under the MIT License.\n\n\"\"\"Aboveground Live Woody Biomass Density dataset.\"\"\"\n\nimport json\nimport os\nfrom collections.abc import Iterable\nfrom typing import Any, Callable, Optional, Union\n\nimport matplotlib.pyplot as plt\nfrom matplotlib.figure import Figure\nfrom rasterio.crs import CRS\n\nfrom .geo import RasterDataset\nfrom .utils import download_url\n\n\nclass AbovegroundLiveWoodyBiomassDensity(RasterDataset):\n    \"\"\"Aboveground Live Woody Biomass Density dataset.\n\n    The `Aboveground Live Woody Biomass Density dataset\n    <https://data.globalforestwatch.org/datasets/gfw::aboveground-live-woody\n    -biomass-density/about>`_\n    is a global-scale, wall-to-wall map of aboveground biomass at ~30m resolution\n    for the year 2000.\n\n    Dataset features:\n\n    * Masks with per pixel live woody biomass density estimates in megagrams\n      biomass per hectare at ~30m resolution (~40,000x40,0000 px)\n\n    Dataset format:\n\n    * geojson file that contains download links to tif files\n    * single-channel geotiffs with the pixel values representing biomass density\n\n    If you use this dataset in your research, please give credit to:\n\n    * `Global Forest Watch <https://data.globalforestwatch.org/>`_\n\n    .. versionadded:: 0.3\n    \"\"\"\n\n    is_image = False\n\n    url = \"https://opendata.arcgis.com/api/v3/datasets/e4bdbe8d6d8d4e32ace7d36a4aec7b93_0/downloads/data?format=geojson&spatialRefId=4326\"  # noqa: E501\n\n    base_filename = \"Aboveground_Live_Woody_Biomass_Density.geojson\"\n\n    filename_glob = \"*N_*E.*\"\n    filename_regex = r\"\"\"^\n        (?P<latitude>[0-9][0-9][A-Z])_\n        (?P<longitude>[0-9][0-9][0-9][A-Z])*\n    \"\"\"\n\n    def __init__(\n        self,\n        paths: Union[str, Iterable[str]] = \"data\",\n        crs: Optional[CRS] = None,\n        res: Optional[float] = None,\n        transforms: Optional[Callable[[dict[str, Any]], dict[str, Any]]] = None,\n        download: bool = False,\n        cache: bool = True,\n    ) -> None:\n        \"\"\"Initialize a new Dataset instance.\n\n        Args:\n            paths: one or more root directories to search or files to load\n            crs: :term:`coordinate reference system (CRS)` to warp to\n                (defaults to the CRS of the first file found)\n            res: resolution of the dataset in units of CRS\n                (defaults to the resolution of the first file found)\n            transforms: a function/transform that takes an input sample\n                and returns a transformed version\n            download: if True, download dataset and store it in the root directory\n            cache: if True, cache file handle to speed up repeated sampling\n\n        Raises:\n            FileNotFoundError: if no files are found in ``paths``\n\n        .. versionchanged:: 0.5\n           *root* was renamed to *paths*.\n        \"\"\"\n        self.paths = paths\n        self.download = download\n\n        self._verify()\n\n        super().__init__(paths, crs, res, transforms=transforms, cache=cache)\n\n    def _verify(self) -> None:\n        \"\"\"Verify the integrity of the dataset.\n\n        Raises:\n            RuntimeError: if dataset is missing\n        \"\"\"\n        # Check if the extracted files already exist\n        if self.files:\n            return\n\n        # Check if the user requested to download the dataset\n        if not self.download:\n            raise RuntimeError(\n                f\"Dataset not found in `paths={self.paths!r}` and `download=False`, \"\n                \"either specify a different `root` directory or use `download=True` \"\n                \"to automatically download the dataset.\"\n            )\n\n        # Download the dataset\n        self._download()\n\n    def _download(self) -> None:\n        \"\"\"Download the dataset.\"\"\"\n        assert isinstance(self.paths, str)\n        download_url(self.url, self.paths, self.base_filename)\n\n        with open(os.path.join(self.paths, self.base_filename)) as f:\n            content = json.load(f)\n\n        for item in content[\"features\"]:\n            download_url(\n                item[\"properties\"][\"Mg_px_1_download\"],\n                self.paths,\n                item[\"properties\"][\"tile_id\"] + \".tif\",\n            )\n\n    def plot(\n        self,\n        sample: dict[str, Any],\n        show_titles: bool = True,\n        suptitle: Optional[str] = None,\n    ) -> Figure:\n        \"\"\"Plot a sample from the dataset.\n\n        Args:\n            sample: a sample returned by :meth:`RasterDataset.__getitem__`\n            show_titles: flag indicating whether to show titles above each panel\n            suptitle: optional string to use as a suptitle\n\n        Returns:\n            a matplotlib Figure with the rendered sample\n        \"\"\"\n        mask = sample[\"mask\"].squeeze()\n        ncols = 1\n\n        showing_predictions = \"prediction\" in sample\n        if showing_predictions:\n            pred = sample[\"prediction\"].squeeze()\n            ncols = 2\n\n        fig, axs = plt.subplots(nrows=1, ncols=ncols, figsize=(ncols * 4, 4))\n\n        if showing_predictions:\n            axs[0].imshow(mask)\n            axs[0].axis(\"off\")\n            axs[1].imshow(pred)\n            axs[1].axis(\"off\")\n            if show_titles:\n                axs[0].set_title(\"Mask\")\n                axs[1].set_title(\"Prediction\")\n        else:\n            axs.imshow(mask)\n            axs.axis(\"off\")\n            if show_titles:\n                axs.set_title(\"Mask\")\n\n        if suptitle is not None:\n            plt.suptitle(suptitle)\n\n        return fig\n", "path": "torchgeo/datasets/agb_live_woody_density.py"}]}