Robotics
      • Sharing URL Link copied
      • /edit
      • View mode
        • Edit mode
        • View mode
        • Book mode
        • Slide mode
        Edit mode View mode Book mode Slide mode
      • Customize slides
      • Note Permission
      • Read
        • Owners
        • Signed-in users
        • Everyone
        Owners Signed-in users Everyone
      • Write
        • Owners
        • Signed-in users
        • Everyone
        Owners Signed-in users Everyone
      • Engagement control Commenting, Suggest edit, Emoji Reply
    • Invite by email
      Invitee

      This note has no invitees

    • Publish Note

      Share your work with the world Congratulations! 🎉 Your note is out in the world Publish Note

      Your note will be visible on your profile and discoverable by anyone.
      Your note is now live.
      This note is visible on your profile and discoverable online.
      Everyone on the web can find and read all notes of this public team.
      See published notes
      Unpublish note
      Please check the box to agree to the Community Guidelines.
      View profile
    • Commenting
      Permission
      Disabled Forbidden Owners Signed-in users Everyone
    • Enable
    • Permission
      • Forbidden
      • Owners
      • Signed-in users
      • Everyone
    • Suggest edit
      Permission
      Disabled Forbidden Owners Signed-in users Everyone
    • Enable
    • Permission
      • Forbidden
      • Owners
      • Signed-in users
    • Emoji Reply
    • Enable
    • Versions and GitHub Sync
    • Note settings
    • Note Insights New
    • Engagement control
    • Make a copy
    • Transfer ownership
    • Delete this note
    • Insert from template
    • Import from
      • Dropbox
      • Google Drive
      • Gist
      • Clipboard
    • Export to
      • Dropbox
      • Google Drive
      • Gist
    • Download
      • Markdown
      • HTML
      • Raw HTML
Menu Note settings Note Insights Versions and GitHub Sync Sharing URL Help
Menu
Options
Engagement control Make a copy Transfer ownership Delete this note
Import from
Dropbox Google Drive Gist Clipboard
Export to
Dropbox Google Drive Gist
Download
Markdown HTML Raw HTML
Back
Sharing URL Link copied
/edit
View mode
  • Edit mode
  • View mode
  • Book mode
  • Slide mode
Edit mode View mode Book mode Slide mode
Customize slides
Note Permission
Read
Owners
  • Owners
  • Signed-in users
  • Everyone
Owners Signed-in users Everyone
Write
Owners
  • Owners
  • Signed-in users
  • Everyone
Owners Signed-in users Everyone
Engagement control Commenting, Suggest edit, Emoji Reply
  • Invite by email
    Invitee

    This note has no invitees

  • Publish Note

    Share your work with the world Congratulations! 🎉 Your note is out in the world Publish Note

    Your note will be visible on your profile and discoverable by anyone.
    Your note is now live.
    This note is visible on your profile and discoverable online.
    Everyone on the web can find and read all notes of this public team.
    See published notes
    Unpublish note
    Please check the box to agree to the Community Guidelines.
    View profile
    Engagement control
    Commenting
    Permission
    Disabled Forbidden Owners Signed-in users Everyone
    Enable
    Permission
    • Forbidden
    • Owners
    • Signed-in users
    • Everyone
    Suggest edit
    Permission
    Disabled Forbidden Owners Signed-in users Everyone
    Enable
    Permission
    • Forbidden
    • Owners
    • Signed-in users
    Emoji Reply
    Enable
    Import from Dropbox Google Drive Gist Clipboard
       Owned this note    Owned this note      
    Published Linked with GitHub
    • Any changes
      Be notified of any changes
    • Mention me
      Be notified of mention me
    • Unsubscribe
    [[_TOC_]] --- # Crossroads Navigating - Report II ## Authors * Tianjian Song (r0815584) * Zhongxi Li (r0866180) ## Introduction From the basis of [last report](https://gitlab.kuleuven.be/rob-ecs/robotics-2022/-/blob/main/Reports/Report-I/Crossroad_scenario/Crossroad_scenario.md), we extend our knowledge graph with extra relations and properties, and describe how to answer the query by traversing the graph in details. ## Robot Task Our robot in this situation has only one purpose - pass the crossroad efficiently and legally. ## Query So the main query to be answered is **"How long can the robot pass the Crossroad?"** The enter and exit are given by the higher level navigation system as hyperparameters. To answer this query, however, requires sub-queries to be answered and they are listed below: - **Query 1**: What kinds of perceptions do I need when I am crossing a crossroad? - **Query 2**: What kinds of motion do I need if I am at a crossroad and there are cars incoming on the right? ## Graph Traversal ### Query 1 Traversal 1. The trigger is the event that a robot is .The relation **Robot_In_Crossroad** could be a _starting_ node to do reasoning about the graph. It can be the output of the algorithm that continuously detecting whether the robot is approaching a crossroad when the robot is driving along the road. 2. Once it gets the trigger, the robot should use the crossroad ID retrieved from the relation **Robot_In_Crossroad** and then it put a _query_: which traffic rules should be followed in this specific crossroad with ID1234? 3. To find out the answer of the above question, the robot needs to traverse the graph to find out all **Crossroad_Traffic_Rule** relations which have an argument **crossroad** with ID1234, and then retrieves the value of property **traffic_rule** of each relation. 4. For each traffic rule it gets, the robot knows that there must be an encoded perception strategy linked to each rule, indicating what kinds of perception tasks it needs to do. For each perception strategy, the robot will look at the argument **robot_perception** to get the list of needed perceptions. There are two possible rules in this context. - In the case of traffic rule being traffic light control, the robot also needs to find out which specific traffic light controls the robot from relation **Traffic_Light_Presence_Control**. According to a **Traffic_Light_Control_Perception_Strategy**, the perception task of the robot is then **Traffic_Light_Detection** (to observe the state of the traffic light) and **Stop_Lines_Detection** (to know where to stop in case the light is red). - If the traffic rule is *Priority_to_Right*, based on the **Priority_To_Right_Perception_Strategy**, the robot should do perception task **Car_Perception** (to detect whether there are cars incoming from the right road) and **Blinker_Detection** (to detect the intension of the incoming cars). 5. After having a list of perception tasks, the robot will need to look at its relation **Robot_Perception_System** to see if it is able to do all the perception tasks in the list. If yes, then the robot starts executing all the tasks. If not, then the robot starts the tasks that it is capable of doing, and at the same time raises warning and seeks other alternatives (which can be encoded as exceptions in the future). ### Query 2 Traversal 1. The robot gets a signal from the navigation system and CV algorithms and the signal represents that the robot is now performing tasks about passing the current crossroad. 2. The query starts at the **Current_Motion_Plan**. From there, the robot knows the relations that needs to be traversed to find the answer of the query. And the following order is: - The robot start by checking the **Crossroad_Traffic_Rule**, in this case, we assume that it tells the robot and the current crossroad is under *Priority_to_Right*. - Then it finds out a template basic motion plan from **Robot_Motion/Robot_Base_Motion_in_Cross** about the general path it needs to follow. - The next step is to analysis the complex situation in crossroad. First, our robot looks at **Car_Perception** to describe the geometric and motion information of other cars from the right side. - Second, it checks **Car_Intention_Prediction**. This relation describe the intention and predict the future moves of the right incoming cars. - Third, it checks **Stop_Lines_Detection**. The stop lines may or may not present in the current crossroad. - **Suggested_Stop_Position** is now can be infereced from the above information. If stop lines are present, it is easier to inferece, but if it doesn't, a complex CV algorithm could be performed to inferece. This relation describes the safe plots for temporary waiting. - Now combining all informations, **Robot_Advanced_Motion_in_Cross** is the answer we will reach, which tactically describe the actions to be taken. The specific action varies depends on the result of perception and dectection. For example, if the right coming car has the intention to do a right turn, then we do not need to give it a hard priority, it could vary depends on its speed, our speed, relative position and human morality setting (we let it go first anyway) 3. The robot executes the suggested action. 4. The process ends, and only start when robot is passing through the current crossroad. The process is performed after Query 1. And they are sequential queries to be answered to achieve the final task: Robot pass through the crossroad. Many hyperparameters can be configured before the process. Human morality like the situation described above can be a example. Also, if one right-coming car pass by our robot and the next one is reacting slowly, leaving our robot a safe break, then we say: OK we can give the robot tolerance. We let our robot break the priority and start moving if the car on the right side does not start accelerating/reacting for 3 seconds while our robot is waiting. Things like this 3 seconds *waiting_time_limit* can be the hyperparameters. ## Further consideration: higher order relation/contraints: **Traffic_Light_Control_Perception_Strategy** and **Priority_To_Right_Perception_Strategy** should just be a _minimum_ perception requirements that the robot needs to comply the current traffic rules. There should be connections to (or compositions of) other kinds of perception requirements under different traffic situations. Both of the perception strategy above could be subclasses of the general **Traffic_Rule_Perception_Strategy**. However, for a car driving on the road, there are more traffic rules for it to follow. For example, whenever the robot hears sirens, in addition to do car detection focused on the crossroad situation in front, it needs to do backwards detection, in order to find out if there are special vehicles coming behind. ## Knowledge graph ### Entities #### Robot ```json { "@type": "https://example.org/robot", "@id": "robot_A", "role_in_traffic": "car" } ``` #### Traffic_Light ```json { "@type": "https://example.org/traffic_light", "@id": "traffic_light_A", "Target_of_Traffic_Light": "car" } ``` #### Traffic_Rule ```json { "@type": "https://example.org/traffic_rule", "@id": "Priority_to_Right" } { "@type": "https://example.org/traffic_rule", "@id": "Traffic_Light_Control" } { "@type": "https://example.org/traffic_rule", "@id": "Emergency_Rule" } ``` #### Crossroad ```json { "@type": "https://example.org/crossroad", "@id": "Crossroad_A" } ``` #### LandMark The reason why geometric signature is property here is because a ground mark is not expected to move. It can be removed, then the corresponding entity will be deleted. ```json { "@type": "https://example.org/LandMark/stopline", "@id": "Stop_Line_1", "geometric_xy": "(10,10)" } ``` #### Motion_Strategy ```json { "@type" : "https://example.org/robot/Motion_Strategy", "@id": "Motion_Strategy", "traversals": ["Relation1" , "Relation2", ...] } ``` ### Relations #### Robot_In_Crossroad ```json { "@type": "https://example.org/In_Crossroad", "@id": "in_crossroad_A", "motion": "enter", "Time Limit(second)" : 300, "arguments": { "robot": {"@id": "robot_A"}, "crossroad": {"@id": "crossroad_A"} } } ``` #### Crossroad_Traffic_Rule ```json { "@type": "https://example.org/crossroad_traffic_rule", "@id": "crossroad_traffic_rule_A", "traffic_rule": {"@id": "Priority_to_Right"}, "arguments": { "crossroad": {"@id": "crossroad_A"}, "traffic_light_presence": {"@id": "traffic_light_Presence_A"} } } ``` #### Traffic_Light_Presence_Control ```json { "@type": "https://example.org/traffic_light_Presence", "@id": "traffic_light_Presence_A", "State": "Presence_And_HasControl", "arguments": { "traffic_light": {"@id": "traffic_light_A"}, "crossroad": {"@id": "crossroad_A"} } } ``` #### Traffic_Light_Control_Perception_Strategy ```json { "@type": "https://example.org/adjustment", "@id": "traffic_rule_Traffic_Light", "arguments": { "traffic_rule": {"@id": "Traffic_Light_Control"}, "robot_perception": [{"@id": "Traffic_Light_Detection"}, {"@id": "Stop_Lines_Detection"}] } } ``` #### Priority_To_Right_Perception_Strategy ```json { "@type": "https://example.org/adjustment", "@id": "traffic_rule_Priority_Right", "arguments": { "traffic_rule": {"@id": "Priority_to_Right"}, "robot_perception": [{"@id": "Car_Detection_A"}] } } ``` #### Traffic_Light_Detection ```json { "@type": "https://example.org/Traffic_Light_Detection", "@id": "Traffic_Light_Detection", "state_of_traffic_light": "red", "arguments": { "robot_in_crossroad": {"@id": "robot_in_crossroad_A"}, } } ``` #### Stop_Lines_Detection ```json { "@type": "https://example.org/Stop_Lines_Detection", "@id": "Stop_Lines_Detection", "list_of_StopLine_positions": [{ "@id": "Stop_Line_1", "@type": "https://example.org/LandMark/stopline", "geometric_xy_value": "(10,10)"}] "arguments": { "robot_in_crossroad": {"@id": "robot_in_crossroad_A"}, "on_the_right": {"@id": "on_the_right_A"} } } ``` #### Car_Perception ```json { "@type": "https://example.org/Car_Perception", "@id": "Car_Perception_A", "Identified_Cars": [{"@id": "car1", "position": "position1", "speed": "speed1"}], "arguments": { "on_the_right": {"@id": "on_the_right_A"} } } ``` #### Blinker_Detection ```json { "@type": "https://example.org/Blinker_Perception", "@id": "Blinker_Perception", "Light_State": ["left-light-on"], "arguments": { "car_perception": {"@id": "Car_Perception_A"} } } ``` #### Car_Intention_Prediction ```json { "@type": "https://example.org/Blinker_Perception", "@id": "Car_Intention_Prediction", "intention": "turn_left", "arguments": { "Blinker_Detection": {"@id": "Blinker_Perception"} } } ``` #### Suggested_Stop_Position ```json { "@type": "https://example.org/Suggested_Stop_Position", "@id": "Suggested_Stop_Position", "ideal_area" : ["Area1"], "arguments": { "Robot_Perception_System": {"@id " : "Robot_Perception_System"} } } ``` #### Robot_Motion ```json { "@type": "https://example.org/Robot_Motion/Robot_Base_Motion_in_Cross", "@id": "Robot_Base_Motion_in_Cross", "Suggested Time Cost(s)": 600, "arguments": { "Robot" : {"@id" : "Robot_A"}, "crossroad": {"@id": "crossroad_A"} } } ``` ```json { "@type": "https://example.org/Robot_Motion/Robot_Advanced_Motion_in_Cross", "@id": "Robot_Advanced_Motion_in_Cross", "Suggested Time Cost(s)": 600, "Expected_React_Time(s)": 3, "Max Waiting time(s)" : 20, "arguments": { "Robot" : {"@id" : "Robot_A"}, "Suggested_Stop_Position": {"@id" : "Suggested_Stop_Position"}, "traffic_rule": {"@id": "Priority_to_Right"}, "Stop_Lines_Detection": {"@id" : "Stop_Lines_Detection"} "Base_Action": {"@id": "Robot_Base_Motion_in_Cross"} } } ``` #### Robot_Perception_System ```json { "@type": "https://example.org/Robot_Perception_System", "@id": "Robot_Perception_System", "robot": {"@id": "robot_A"}, "arguments": { "perception_systems" : [{"@id" : "Car_Perception"}, {"@id" : "Traffic_Light_Detection"}, {"@id" : "Stop_Lines_Detection"}, {"@id" : "Car_Intention_Prediction"}] } } ``` #### Current_Motion_Plan ```json { "@type": "https://example.org/Current_Motion_Plan", "@id": "Current_Motion_Plan", "Plan" : "Motion_Strategy" "arguments": { "Robot": {"@id": "Robot_A"}, "Crossroad": {"@id": "Crossroad_A"} } } ```

    Import from clipboard

    Paste your markdown or webpage here...

    Advanced permission required

    Your current role can only read. Ask the system administrator to acquire write and comment permission.

    This team is disabled

    Sorry, this team is disabled. You can't edit this note.

    This note is locked

    Sorry, only owner can edit this note.

    Reach the limit

    Sorry, you've reached the max length this note can be.
    Please reduce the content or divide it to more notes, thank you!

    Import from Gist

    Import from Snippet

    or

    Export to Snippet

    Are you sure?

    Do you really want to delete this note?
    All users will lose their connection.

    Create a note from template

    Create a note from template

    Oops...
    This template has been removed or transferred.
    Upgrade
    All
    • All
    • Team
    No template.

    Create a template

    Upgrade

    Delete template

    Do you really want to delete this template?
    Turn this template into a regular note and keep its content, versions, and comments.

    This page need refresh

    You have an incompatible client version.
    Refresh to update.
    New version available!
    See releases notes here
    Refresh to enjoy new features.
    Your user state has changed.
    Refresh to load new user state.

    Sign in

    Forgot password

    or

    By clicking below, you agree to our terms of service.

    Sign in via Facebook Sign in via Twitter Sign in via GitHub Sign in via Dropbox Sign in with Wallet
    Wallet ( )
    Connect another wallet

    New to HackMD? Sign up

    Help

    • English
    • 中文
    • Français
    • Deutsch
    • 日本語
    • Español
    • Català
    • Ελληνικά
    • Português
    • italiano
    • Türkçe
    • Русский
    • Nederlands
    • hrvatski jezik
    • język polski
    • Українська
    • हिन्दी
    • svenska
    • Esperanto
    • dansk

    Documents

    Help & Tutorial

    How to use Book mode

    Slide Example

    API Docs

    Edit in VSCode

    Install browser extension

    Contacts

    Feedback

    Discord

    Send us email

    Resources

    Releases

    Pricing

    Blog

    Policy

    Terms

    Privacy

    Cheatsheet

    Syntax Example Reference
    # Header Header 基本排版
    - Unordered List
    • Unordered List
    1. Ordered List
    1. Ordered List
    - [ ] Todo List
    • Todo List
    > Blockquote
    Blockquote
    **Bold font** Bold font
    *Italics font* Italics font
    ~~Strikethrough~~ Strikethrough
    19^th^ 19th
    H~2~O H2O
    ++Inserted text++ Inserted text
    ==Marked text== Marked text
    [link text](https:// "title") Link
    ![image alt](https:// "title") Image
    `Code` Code 在筆記中貼入程式碼
    ```javascript
    var i = 0;
    ```
    var i = 0;
    :smile: :smile: Emoji list
    {%youtube youtube_id %} Externals
    $L^aT_eX$ LaTeX
    :::info
    This is a alert area.
    :::

    This is a alert area.

    Versions and GitHub Sync
    Get Full History Access

    • Edit version name
    • Delete

    revision author avatar     named on  

    More Less

    Note content is identical to the latest version.
    Compare
      Choose a version
      No search result
      Version not found
    Sign in to link this note to GitHub
    Learn more
    This note is not linked with GitHub
     

    Feedback

    Submission failed, please try again

    Thanks for your support.

    On a scale of 0-10, how likely is it that you would recommend HackMD to your friends, family or business associates?

    Please give us some advice and help us improve HackMD.

     

    Thanks for your feedback

    Remove version name

    Do you want to remove this version name and description?

    Transfer ownership

    Transfer to
      Warning: is a public team. If you transfer note to this team, everyone on the web can find and read this note.

        Link with GitHub

        Please authorize HackMD on GitHub
        • Please sign in to GitHub and install the HackMD app on your GitHub repo.
        • HackMD links with GitHub through a GitHub App. You can choose which repo to install our App.
        Learn more  Sign in to GitHub

        Push the note to GitHub Push to GitHub Pull a file from GitHub

          Authorize again
         

        Choose which file to push to

        Select repo
        Refresh Authorize more repos
        Select branch
        Select file
        Select branch
        Choose version(s) to push
        • Save a new version and push
        • Choose from existing versions
        Include title and tags
        Available push count

        Pull from GitHub

         
        File from GitHub
        File from HackMD

        GitHub Link Settings

        File linked

        Linked by
        File path
        Last synced branch
        Available push count

        Danger Zone

        Unlink
        You will no longer receive notification when GitHub file changes after unlink.

        Syncing

        Push failed

        Push successfully