load-and-parse-plate-boundary-data

star 50

Load plate boundary GeoJSON and create a GeoDataFrame with proper geometry parsing. Verify column names (PlateA, PlateB) match the dataset structure. Use this skill to prepare boundary data before filtering for Pacific plate relevance.

cxcscmu By cxcscmu schedule Updated 4/24/2026

name: Load and Parse Plate Boundary Data description: Load plate boundary GeoJSON and create a GeoDataFrame with proper geometry parsing. Verify column names (PlateA, PlateB) match the dataset structure. Use this skill to prepare boundary data before filtering for Pacific plate relevance.

def load_boundary_data(filepath):
    """
    Load plate boundary data and parse geometries correctly.
    
    Args:
        filepath: Path to PB2002_boundaries.json
        
    Returns:
        GeoDataFrame with boundary geometries and plate identifiers
    """
    boundaries = gpd.read_file(filepath)
    
    # Verify expected columns exist
    if 'PlateA' not in boundaries.columns or 'PlateB' not in boundaries.columns:
        print("Available columns:", boundaries.columns.tolist())
        raise ValueError("PlateA and PlateB columns not found")
    
    # Ensure geometry is valid
    boundaries = boundaries[boundaries.geometry.is_valid]
    boundaries = boundaries.reset_index(drop=True)
    
    return boundaries
Install via CLI
npx skills add https://github.com/cxcscmu/SkillLearnBench --skill load-and-parse-plate-boundary-data
Repository Details
star Stars 50
call_split Forks 3
navigation Branch main
article Path SKILL.md
More from Creator