Exports¶
Export flight plans to various pilot, archival, and briefing formats.
Functions¶
- to_excel(plan, filepath, aircraft=None, takeoff_time=None, mission_name='')[source]¶
Write a full MovingLines-compatible working Excel file.
This produces the 24-column format (A-X) that MovingLines uses as its internal working format, enabling round-tripping between tools.
The
HdWind [kt]/HdWind [m/s]columns are populated from the plan’s per-segment along-track wind (tailwind_kts, written by wind-awarecompute_flight_plan()runs) and are 0 for plans computed without wind.delayTandClimbTare always written as 0 — hyplan folds delays and climb time into segment timing.- Parameters:
plan (
GeoDataFrame) – Flight plan GeoDataFrame fromcompute_flight_plan().filepath (
str) – Output.xlsxpath.aircraft (
object) – Optional Aircraft object for metadata.takeoff_time (
datetime|None) – UTC datetime of takeoff. If None, times are shown as elapsed minutes from 00:00 UTC.mission_name (
str) – Campaign / mission name string.
- Return type:
- to_pilot_excel(plan, filepath, aircraft=None, takeoff_time=None, mission_name='', coord_format='DD MM', include_mag_heading=False)[source]¶
Write a simplified pilot-facing Excel file.
Matches the MovingLines
_for_pilots.xlsxformat.- Parameters:
plan (
GeoDataFrame) – Flight plan GeoDataFrame fromcompute_flight_plan().filepath (
str) – Output.xlsxpath.aircraft (
object) – Optional Aircraft object for metadata (type, tail number).mission_name (
str) – Campaign / mission name.coord_format (
str) – Coordinate display format — one of'DD MM','DD MM SS','NDDD MM.SS'.include_mag_heading (
bool) – Include a magnetic heading column. Requires the optionalgeomagpackage (pip install hyplan[mag]); off by default so the export works in conda-only installs.
- Return type:
- to_kml(plan, filepath, takeoff_time=None, altitude_exaggeration=1.0, write_kmz=False)[source]¶
Write a KML (and optionally KMZ) file for Google Earth.
Matches the MovingLines
save2kmllayout.- Parameters:
plan (
GeoDataFrame) – Flight plan GeoDataFrame.filepath (
str) – Output.kmlor.kmzpath.altitude_exaggeration (
float) – Multiplier for altitude in the KML coordinates (default 1.0 = true scale; MovingLines uses 10).write_kmz (
bool) – If True and filepath is a.kmlpath, also write a.kmzcompanion alongside it (default False).
- Return type:
- to_gpx(plan, filepath, mission_name='', takeoff_time=None)[source]¶
Write a GPX route file.
Matches the MovingLines
save2gpxformat.
- to_foreflight_csv(plan, filepath, takeoff_time=None, write_oneline=True)[source]¶
Write a ForeFlight-compatible CSV file.
Matches the MovingLines
_FOREFLIGHT.csvformat. By default also writes a companion_oneline.txtfile next to filepath for ForeFlight content-pack parity.
- to_honeywell_fms(plan, filepath, takeoff_time=None)[source]¶
Write a Honeywell FMS-compatible CSV file.
Matches the MovingLines
_Honeywell.csvformat for Gulfstream III/IV avionics.
- to_er2_csv(plan, filepath, takeoff_time=None)[source]¶
Write an ER-2-compatible CSV file.
Matches the MovingLines ER-2 export format.
- to_icartt(plan, filepath, pi_name='', institution='', mission_name='', flight_date=None, aircraft=None, takeoff_time=None, interval_seconds=60.0, revision='RA', revision_comments='RA: Planned flight track - pre-flight', special_comments='', normal_comments='')[source]¶
Write an ICARTT v1001 file.
Matches the MovingLines
save2ict/write_ictformat. Data is linearly interpolated along the flight plan at interval_seconds intervals.- Parameters:
plan (
GeoDataFrame) – Flight plan GeoDataFrame.filepath (
str) – Output.ictpath.pi_name (
str) – Principal investigator name.institution (
str) – PI institution.mission_name (
str) – Campaign name.flight_date (
date|None) – Flight date. Defaults to the (UTC) date of takeoff_time when given, otherwise today.aircraft (
object) – Aircraft object (for platform name).takeoff_time (
datetime|None) – UTC takeoff time. If None, Start_UTC begins at 0.interval_seconds (
float) – Interpolation interval in seconds (default 60).revision (
str) – Revision code (RA, RB, R0, R1, …).revision_comments (
str) – Revision description string.special_comments (
str) – Additional special comment lines.normal_comments (
str) – Additional normal comment lines.
- Return type:
- to_txt(plan, filepath, takeoff_time=None)[source]¶
Write a plain text waypoint file.
Matches the MovingLines
save2txtformat. Note: Lon comes before Lat (opposite of the Excel format).
- to_trackair(plan, filepath, sensor=None, terrain_elevation_m=0.0, author='', mission_name='')[source]¶
Export flight plan to TrackAir scanner planning format.
TrackAir is an INI-style format used with HyMap and HySpex line-scanner sensors. The
[strips]section lists each straight data-collection segment asN=lat1,lon1,lat2,lon2in decimal degrees.- Parameters:
plan (
GeoDataFrame) – GeoDataFrame returned bycompute_flight_plan().filepath (
str) – Output file path (typically*.txt).sensor (
Any) – OptionalLineScannerinstance used to populate the[spex]field-of-view and swath-width fields.terrain_elevation_m (
float) – Terrain elevation in metres used to convert MSL altitude to AGL. Defaults to 0 (sea-level terrain).author (
str) – Name written toDesigned byfields.mission_name (
str) – Written toFlight plan name.
- Return type: