-
Notifications
You must be signed in to change notification settings - Fork 44
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #135 from tomsch420/costmaps
Refactored Costmaps using new probabilistic models and exact inference.
- Loading branch information
Showing
26 changed files
with
84,994 additions
and
1,149 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
-r requirements.txt | ||
probabilistic_model>=4.0.8 | ||
random_events>=2.0.9 | ||
SQLAlchemy | ||
tqdm |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Empty file.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,51 @@ | ||
import sqlalchemy.orm | ||
from sqlalchemy import Select, alias | ||
from ..task import TaskTreeNode | ||
from ..action_designator import PickUpAction | ||
from ..base import Position, RobotState, Pose | ||
from ..object_designator import Object | ||
|
||
|
||
class Query: | ||
""" | ||
Abstract class for queries | ||
""" | ||
|
||
|
||
class PickUpWithContext(Query): | ||
""" | ||
Query for pickup actions with context. | ||
""" | ||
|
||
robot_position = sqlalchemy.orm.aliased(Position) | ||
""" | ||
3D Vector of robot position | ||
""" | ||
|
||
robot_pose = sqlalchemy.orm.aliased(Pose) | ||
""" | ||
Complete robot pose | ||
""" | ||
|
||
object_position = sqlalchemy.orm.aliased(Position) | ||
""" | ||
3D Vector for object position | ||
""" | ||
|
||
relative_x = (robot_position.x - object_position.x).label("relative_x") | ||
""" | ||
Distance on x axis between robot and object | ||
""" | ||
|
||
relative_y = (robot_position.y - object_position.y).label("relative_y") | ||
""" | ||
Distance on y axis between robot and object | ||
""" | ||
|
||
def join_statement(self, query: Select): | ||
return (query.join(TaskTreeNode).join(TaskTreeNode.action.of_type(PickUpAction)) | ||
.join(PickUpAction.robot_state).join(self.robot_pose, RobotState.pose) | ||
.join(self.robot_position, self.robot_pose.position) | ||
.join(Pose.orientation) | ||
.join(PickUpAction.object) | ||
.join(Object.pose).join(self.object_position, Pose.position)) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +0,0 @@ | ||
from .location.jpt_location import JPTCostmapLocation | ||
Oops, something went wrong.