Deep learning with remote sensing data.
Project description
### Quick start
```python
import os
import matpoltib.pyplpot as plt
from aeronet.dataset.raster import BandCollection
from aeronet.dataset import RandomDataset
from aeronet.dataset.utils import parse_direcotry
from aeronet.dataset.visualization import add_mask
# configuration
SRC_DIR = '/path/to/elements/'
channels = ['RED', 'GRN', 'BLU']
labels = ['100']
# directories of dataset elements
dirs = [os.path.join(SRC_DIR, x) for x in os.listdir(SRC_DIR)]
print('Found collections: ', len(dirs), end='\n\n')
# parse channels in directories
band_paths = [parse_direcotry(x, channels + labels) for x in dirs]
print('BandCollection 0 paths:\n', band_paths[0], end='\n\n')
# convert to `BandCollection` objects
band_collections = [BandCollection(fps) for fps in band_paths]
print('BandCollection 0 object:\n', repr(band_collections[0]))
# create random dataset sampler
dataset = RandomDataset(band_collections,
sample_size=(512, 512),
input_channels=channels,
output_labels=labels,
transform=None) # pre-processing function
# get random sample
generated_sample = dataset[0]
image = generated_sample['image']
mask = generated_sample['mask']
#visualize
masked_image = add_mask(image, mask)
plt.figure(figsize=(10,10))
plt.imshow(masked_image)
plt.show()
```
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distributions
No source distribution files available for this release.See tutorial on generating distribution archives.
Built Distribution
Close
Hashes for aeronet-0.0.2-py2.py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | b1ad9f6abdbcb55376b84add290218cd2c0958c89c5c6e9a734d22692e89564f |
|
MD5 | 10989469b70dfce71191cc0b65ba2a40 |
|
BLAKE2b-256 | ae6fd14e5689e2df93b4b04aaad8bcd16351fc60f4bc54e704ec7020630ea966 |