Flight plan - HALO-20240916a#
ec_under ec_track c_north c_mid c_south pace_under curtainCrew#
Job |
Name |
---|---|
PI |
Konstantin Krüger |
WALES |
Dimitra Kouklaki |
HAMP |
Georgios Dekoutsidis |
Dropsondes |
Nina Robbins |
Smart/VELOX |
Michael Schäfer |
SpecMACS |
Anja Stallmach |
Flight Documentation |
Manfred Wendisch |
Ground contact |
Raphaela Vogel |
Flight plan#
Show code cell source
from datetime import datetime
import orcestra.sat
from orcestra.flightplan import bco, point_on_track, LatLon, IntoCircle, FlightPlan
#import topojson
#import json
# Some fixed coordinates
lon_min, lon_max, lat_min, lat_max = -65, -20, 0, 20
airport = bco
radius = 72e3*1.852
# Define dates for flight
flight_time = datetime(2024, 9, 16, 12, 0, 0)
flight_index = f"HALO-{flight_time.strftime('%Y%m%d')}a"
# Load satellite tracks
ec_fcst_time = "2024-09-15"
ec_track = orcestra.sat.SattrackLoader("EARTHCARE", ec_fcst_time, kind="PRE",roi="BARBADOS") \
.get_track_for_day(f"{flight_time:%Y-%m-%d}")\
.sel(time=slice(f"{flight_time:%Y-%m-%d} 14:00", None))
# Use PACE_loader once only
pace_track = orcestra.sat.pace_track_loader() \
.get_track_for_day(f"{flight_time:%Y-%m-%d}")
pace_track = pace_track.where(
(pace_track.lat >lat_min)&
(pace_track.lat <lat_max)&
(pace_track.lon >-60)&
(pace_track.lon <-30),
drop = True) \
.sel(time=slice(f"{flight_time:%Y-%m-%d} 11:00", f"{flight_time:%Y-%m-%d} 21:00"))
# Create elements of track
c_north = point_on_track(ec_track,lat= 11.5).assign(label = "c_north")
c_south = LatLon(lat= 7, lon= -50).assign(label = "c_south")
c_mid = point_on_track(ec_track,lat= 8.7).assign(label = "c_mid")
ec_north = point_on_track(ec_track, lat= 9).assign(label = "ec_north")
ec_south = point_on_track(ec_track, lat= 3.0).assign(label = "ec_south")
ec_under = point_on_track(ec_track, lat= 5.5, with_time=True).assign(label = "ec_under", note = "meet EarthCARE")
pace_north = point_on_track(pace_track,lat= 8).assign(label = "pace_north")
pace_under = point_on_track(pace_track,lat= 6).assign(label = "pace_under")
pace_south = point_on_track(pace_track,lat= 3.0).assign(label = "pace_south")
c_south_entry = point_on_track(pace_track,c_south.lat+1.1).assign(label = "c_south_entry")
c_north_home = point_on_track(ec_track, lat= c_north.lat - 1.25).assign(label = "c_north_home")
#c_wait4EC = point_on_track(pace_track, lat= pace_south.lat+0.75).assign(label = "c_wait4EC")
c_wait4EC = point_on_track(pace_track, lat= pace_south.lat).assign(label = "c_wait4EC")
#point_atlantic = LatLon(lat= ec_south.lat, lon= -47).assign(label = "c_south")
waypoints = [
#airport.assign(fl=0, time = ""),
airport.assign(fl=0),
IntoCircle(c_mid.assign(fl=410), radius, -360),
c_south_entry.assign(fl=410),
IntoCircle(c_south.assign(fl=410), radius, -360),
pace_north.assign(fl=450),
pace_under.assign(fl=450),
#point_atlantic.assign(fl=450),
IntoCircle(c_wait4EC.assign(fl=450), radius=36e3, angle=280),
pace_south.assign(fl=450),
ec_south.assign(fl=450),
ec_under.assign(fl=450),
ec_north.assign(fl=450),
IntoCircle(c_north.assign(fl=450), radius, 360),
c_north_home.assign(fl=450),
airport.assign(fl=0),
]
# Crew
crew = {'Mission PI': 'Konstantin Krüger',
'DropSondes': 'Nina Robbins',
'HAMP': 'Georgios Dekoutsidis',
'SMART/VELOX': 'Michael Schäfer',
'SpecMACS': 'Anja Stallmach',
'WALES' : 'Dimitra Kouklaki',
'Flight Documentation': 'Manfred Wendisch',
'Ground Support': 'Raphaela Vogel'
}
# Plan
plan = FlightPlan(waypoints, flight_index, crew=crew, aircraft="HALO")
print(f"Flight index: {plan.flight_id}")
print(f"Take-off: {plan.takeoff_time:%H:%M %Z}\nLanding: {plan.landing_time:%H:%M %Z}\n")
/home/runner/miniconda3/envs/orcestra_book/lib/python3.12/site-packages/orcestra/sat.py:183: UserWarning: You are using an old forecast (issued on 2024-09-15) for EARTHCARE on 2024-09-16! The newest forecast issued so far was issued on 2024-09-16. It's a PRE forecast.
warnings.warn(
Flight index: HALO-20240916a
Take-off: 11:54 UTC
Landing: 20:48 UTC
Show code cell source
import matplotlib.pyplot as plt
import cartopy.crs as ccrs
import easygems.healpix as egh
import intake
from orcestra.flightplan import plot_cwv, plot_path
import numpy as np
#with open("worldfirs.json", 'r') as f:
# data = json.load(f)
## parse topojson file using `object_name`
#topo = topojson.Topology(data, object_name="data")
#firs = topo.to_gdf()
#for i, row in firs.iterrows():
# for geom in getattr(row.geometry.boundary, "geoms", [row.geometry.boundary]):
# lon, lat = zip(*list(geom.coords))
# ax.plot(lon, lat, transform=ccrs.PlateCarree(), color='k', lw=1)
#forecast_overlay = True
forecast_overlay = True
plt.figure(figsize = (14, 8))
ax = plt.axes(projection=ccrs.PlateCarree())
ax.set_extent([lon_min, lon_max, lat_min, lat_max], crs=ccrs.PlateCarree())
ax.coastlines(alpha=1.0)
ax.gridlines(draw_labels=True, dms=True, x_inline=False, y_inline=False, alpha = 0.25)
if (forecast_overlay):
ifs_fcst_time = datetime(2024, 9, 14, 0, 0, 0)
ds = intake.open_catalog("https://tcodata.mpimet.mpg.de/internal.yaml").HIFS(datetime = ifs_fcst_time).to_dask().pipe(egh.attach_coords)
cwv_flight_time = ds["tcwv"].sel(time=flight_time, method = "nearest")
plot_cwv(cwv_flight_time, levels = [48.0, 50.0, 52.0, 54.0, 56.0, 58.0, 60.0], ax=ax)
plt.title(f"{flight_time}\n(CWV forecast issued on {ifs_fcst_time})")
#uwind = ds["10u"].sel(time=flight_time, method = "nearest")
plt.plot(ec_track.lon, ec_track.lat, c='k', ls='dotted')
plt.scatter(pace_track.lon, pace_track.lat, s=10, color='darkgreen')
plt.fill_betweenx(pace_track.lat, pace_track.lon,pace_track.lon+1,color='limegreen',alpha=0.2)
plt.fill_betweenx(pace_track.lat, pace_track.lon,pace_track.lon-1,color='limegreen',alpha=0.2)
plot_path(plan, ax, color="C1")
Show code cell source
from orcestra.flightplan import vertical_preview
vertical_preview(waypoints)
Show code cell source
plan.show_details()
plan.export()
Detailed Overview:
BCO N13 09.76, W059 25.72, FL000, 11:54:15 UTC,
circle around c_mid N08 42.00, W047 27.59, FL410, 13:41:42 UTC - 14:41:15 UTC, radius: 72 nm, 360° CCW, enter from west
to c_south_entry N08 06.00, W050 23.16, FL410, 14:57:34 UTC,
circle around c_south N07 00.00, W050 00.00, FL410, 14:57:53 UTC - 15:57:26 UTC, radius: 72 nm, 360° CCW, enter from north
to pace_north N08 00.00, W050 21.89, FL450, 15:58:33 UTC,
to pace_under N06 00.00, W049 56.42, FL450, 16:14:21 UTC,
circle around c_wait4EC N03 00.00, W049 18.46, FL450, 16:35:32 UTC - 16:47:50 UTC, radius: 19 nm, 280° CW, enter from north
to pace_south N03 00.00, W049 18.46, FL450, 16:50:21 UTC,
to ec_south N03 00.00, W048 31.75, FL450, 16:56:24 UTC,
to ec_under N05 30.00, W048 03.72, FL450, 17:16:03 UTC, meet EarthCARE
to ec_north N09 00.00, W047 24.18, FL450, 17:43:35 UTC,
circle around c_north N11 30.00, W046 55.64, FL450, 17:53:56 UTC - 18:52:29 UTC, radius: 72 nm, 360° CW, enter from south
to c_north_home N10 15.00, W047 09.95, FL450, 18:53:00 UTC,
to BCO N13 09.76, W059 25.72, FL000, 20:48:03 UTC,