Upload EuroSAT.py with huggingface_hub
Browse files- EuroSAT.py +2 -2
EuroSAT.py
CHANGED
|
@@ -81,8 +81,8 @@ class EuroSAT(datasets.GeneratorBasedBuilder):
|
|
| 81 |
"River",
|
| 82 |
"SeaLake",
|
| 83 |
]
|
| 84 |
-
self.num_channels = len(self.config.band_indices)
|
| 85 |
super().__init__(*args, **kwargs)
|
|
|
|
| 86 |
# if 'config' in kwargs:
|
| 87 |
# user_config = kwargs['config']
|
| 88 |
# if isinstance(user_config, dict):
|
|
@@ -99,7 +99,7 @@ class EuroSAT(datasets.GeneratorBasedBuilder):
|
|
| 99 |
def _info(self):
|
| 100 |
return datasets.DatasetInfo(
|
| 101 |
features=datasets.Features({
|
| 102 |
-
"image": datasets.Array3D(shape=(self.
|
| 103 |
"label": datasets.ClassLabel(names=self.labels),
|
| 104 |
}),
|
| 105 |
supervised_keys=("image", "label")
|
|
|
|
| 81 |
"River",
|
| 82 |
"SeaLake",
|
| 83 |
]
|
|
|
|
| 84 |
super().__init__(*args, **kwargs)
|
| 85 |
+
self.num_channels = len(self.config.band_indices)
|
| 86 |
# if 'config' in kwargs:
|
| 87 |
# user_config = kwargs['config']
|
| 88 |
# if isinstance(user_config, dict):
|
|
|
|
| 99 |
def _info(self):
|
| 100 |
return datasets.DatasetInfo(
|
| 101 |
features=datasets.Features({
|
| 102 |
+
"image": datasets.Array3D(shape=(len(self.config.band_indices), self.height, self.width), dtype="float32"),
|
| 103 |
"label": datasets.ClassLabel(names=self.labels),
|
| 104 |
}),
|
| 105 |
supervised_keys=("image", "label")
|