Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[uss_qualifier] Use FlightInfoTemplate for flight intent storage #276

Merged

Conversation

BenjaminPelletier
Copy link
Member

This PR continues the transition away from the legacy scd flight planning API by changing the flight intent storage format from being based on InjectFlightRequest (scd API) to being based on FlightInfoTemplate. The CHE flight intent test data is updated to this new format, and the vertices are shortened to just a bounding box (rather than rounded-edge rectangles) for easier readability. The Kentland flight data was unused, so therefore it is deleted in this PR to reduce maintenance burden.

To allow reuse, resolving a FlightIntentCollection (with delta definitions) to a concrete collection is moved to the FlightIntentCollection object itself.

Because verifying the new flight intent data was hard, a small script to render a FlightIntentCollection as a Google Earth KML is added to the test_data folder.

The wrong Polygon type was being referenced in geotemporal, so this is fixed.

@BenjaminPelletier BenjaminPelletier marked this pull request as ready for review October 21, 2023 01:59
Copy link
Contributor

@mickmis mickmis left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM - there is just a change in the apply_overrides that I did not 100% understand but I think has an small issue without impact - to be double-checked.

volumes = []
else:
raise ValueError(
f"Unrecongized uas_state '{info.basic_information.uas_state}'"
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
f"Unrecongized uas_state '{info.basic_information.uas_state}'"
f"Unrecognized uas_state '{info.basic_information.uas_state}'"

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks; done

result = ImplicitDict.parse(base_object, type(base_object))
if isinstance(base_object, dict):
result = {k: v for k, v in base_object.items()}
elif base_object is None:
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is never true because of

    if base_object is None:
        return overrides

at the beginning of the function.

Or did you mean the following?

Suggested change
elif base_object is None:
elif overrides is None:

But if so, could that be true? I.e. can both isinstance(overrides, dict) and overrides is None be true at the same time?

But IIUC the condition+return can just be removed and that's not an issue.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I agree -- I think the issue I was trying to address was separate from this so I've removed the clause

Comment on lines +79 to +80
test scenario. Additionally, their end time must leave sufficient time for the execution of the test scenario. For the
sake of simplicity, it is recommended to set the start and end times of all the intents to the same range.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This change should probably be also done on:

  • monitoring/uss_qualifier/scenarios/astm/utm/nominal_planning/conflict_higher_priority/conflict_higher_priority.md
  • monitoring/uss_qualifier/scenarios/astm/utm/flight_intent_validation/flight_intent_validation.md

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sounds good -- done

@BenjaminPelletier BenjaminPelletier merged commit a09aac7 into interuss:main Oct 24, 2023
9 checks passed
@BenjaminPelletier BenjaminPelletier deleted the flight-intent-storage branch October 24, 2023 15:07
github-actions bot added a commit that referenced this pull request Oct 24, 2023
* Use FlightInfoTemplate for flight intent storage

* Address comments a09aac7
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants