@classmethod
def from_file_name(cls, hgt_name: str):
    """Create an instance from a HGT name, eg "N38W006" """
    hgt_name = hgt_name.upper()
    error = f'Invalid hgt name ({hgt_name}), expected format (N|S)00(E|W)000'
    assert len(hgt_name) == 7, error
    assert hgt_name[0] in ('N', 'S'), error
    assert hgt_name[3] in ('E', 'W'), error
    try:
        is_north = hgt_name[0] == 'N'
        latitude = int(hgt_name[1:3])
        is_east = hgt_name[3] == 'E'
        longitude = int(hgt_name[4:7])
    except ValueError:
        assert False, error
    if not is_north:
        latitude *= -1
    if not is_east:
        longitude *= -1
    return cls(latitude=latitude, longitude=longitude)
