-
Notifications
You must be signed in to change notification settings - Fork 0
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
Feature/map loc #66
base: develop
Are you sure you want to change the base?
Feature/map loc #66
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Some documentation issues. I think you have the actual docstrings on your personal machine, however they did not transfer into the pushed file, hopefully we can figure that out on Thursday.
# Takes in tuple(start location, map height), altitude, and focal_length] | ||
# Assumes altitude and focal_length doesn't change | ||
# Returns flight path of drone to snap images of map |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
These few comments aren't needed, as all this information should be in the docstring.
flight/protoMap.py
Outdated
print("Camera Width:", cam_w) | ||
print("Camera Height:", cam_h) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Print statements can be commented out or removed, this information will more likely than not be added into a config file or logging statements in the near future.
flight/protoMap.py
Outdated
print("Map Width:", map_w) | ||
print("Map Height:", map_h) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Same as previous comment; remove/comment print statements
flight/protoMap.py
Outdated
# Flight path algorithm | ||
pass |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Import the testing algorithm here or call the function that contains that algorithm
|
||
Returns | ||
------- | ||
(cam_w, cam_h): Tuple[float, float] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
A short note on what this tuple contains and is used for would be appreciated.
center: Tuple[float, float], | ||
map_w: float, | ||
map_h: float, | ||
) -> List[Tuple[float, float]]: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This function also needs a formal docstring.
flight/protoMap.py
Outdated
|
||
|
||
# https://stackoverflow.com/questions/7222382/get-lat-long-given-current-point-distance-and-bearing | ||
def conversion(coord: Tuple[float, float], bearing: float, distance: float) -> Tuple[float, float]: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This function also needs a formal docstring.
|
||
return (new_lat, new_lon) | ||
|
||
def flight_path(points: List[Tuple[float, float]], col: int) -> List[Tuple[float, float]]: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This function needs a formal docstring as well.
new_arr = [] | ||
temp = [] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
These two arrays need type annotations.
if i % 2 != 0: | ||
new_arr[i].reverse() | ||
|
||
path = [] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
path also needs a type annotation
9b8341c
to
55d9d83
Compare
Completed creating waypoint locations in lat,long coordinates for mapping.