spacenet.datasets.load_dataset#
- spacenet.datasets.load_dataset(dataset_name='Spiral')#
Loads a point cloud dataset for testing and demonstration purposes. The function supports multiple predefined datasets, such as ‘spiral’, ‘cylinder’, and ‘sphere’. Each dataset is stored as a CSV file containing the coordinates of the points in the point cloud, along with any additional attributes relevant to the dataset.
- Parameters:
- dataset_namestr
The name of the dataset to load. Available datasets: [‘spiral’, ‘cylinder’, ‘sphere’]. Default is ‘Spiral’.
- Returns:
- pointcloud_dataframepandas.DataFrame
A DataFrame containing the point cloud data for the specified dataset. The DataFrame should have columns corresponding to the coordinates of the points (e.g., ‘x’, ‘y’, ‘z’) and any additional attributes relevant to the dataset.
Examples
You can use the load_dataset function to load different point cloud datasets for testing and demonstration purposes. Below is an example of how to load the Spiral dataset and display the first few rows of the resulting DataFrame.
import spacenet as sn # get data from the Spiral dataset sprial_df = sn.datasets.load_dataset('spiral') print(sprial_df.head())