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

Pacman demo #63

Merged
merged 168 commits into from
Oct 31, 2024
Merged

Pacman demo #63

merged 168 commits into from
Oct 31, 2024

Conversation

orzechow
Copy link
Member

@orzechow orzechow commented Oct 29, 2024

Finally, we're very close to merge the long-awaited demo.

  • Update Readme

orzechow and others added 30 commits April 12, 2024 10:52
  > Split headers from source files for a clean install
This uses the submodule version of EnTT instead of the installed version
as a workaround since the installed version gave me compile errors.
Update positions in separate function and move to cpp
Implement a wrapper class for the pacman game that handles all the SDL
stuff, the game loop etc. This simplifies the main.cpp by quite a bit
and allows to see whats actually important.
Co-authored-by: Piotr Spieker <[email protected]>

- Remove MRT leftovers
- Remove unnecesseary doxygen string
- Do not track isActive in runAwayFromGhostBehavior
- Undo feedback commit: Position operator+ cannot return a reference
- Rename PacmanArbitrator to PacmanAgent
- Rename Direction::NONE to Direction::LAST
- Consider the tunnel when computen the distance in A*
- Replace global variable possibleMoves by static function
- Fix tests where aStar was not properly initialized
- Remove mounting of /dev/dri
- Fix some includes
…ults

- Function returns both the distance and the position to remove unecessary
recompute
- Cache closestGhost computation using util_caching
@orzechow
Copy link
Member Author

Alright, I've updated the Readme a bit.

Regarding the feature list, this could be an alternative formatting (a bit cleaner, but longer):

Details

  • Bottom-up 🌱
    Combine simple atomic behavior components to generate complex behaviors.
  • Functional decomposition 🧩
    Behavior components define the How to do it? and Can we do it?, while Arbitrators take the decision on What to do?
  • Meta-framework 🧠
    Integrate diverse methods in one decision-making framework. Why not combine optimization-based planning, probabilistic approaches (POMDPs), and machine learning (RL)? Use any approach where it performs best!
  • Scalability 📈
    Stack behavior components in arbitrators to create hierarchical behavior models.
  • Maintainability 🛠️
    Add new behaviors without having to touch others – did we mention strict modularity and functional decomposition?
  • Transparency 💡
    Easily follow and understand the decision-making process.
  • Behavior Verification 🛡️
    Use tightly integrated verifiers to ensure only valid and safe behavior commands are executed.
  • Graceful Degradation 🪂
    Your behavior is unreliable or unsafe? Arbitrators will gracefully fall back to the next-best option.

@orzechow orzechow marked this pull request as ready for review October 30, 2024 13:37
@orzechow orzechow requested review from ll-nick and removed request for ChristophBurger89 and ll-nick October 30, 2024 13:37
Copy link
Collaborator

@ll-nick ll-nick left a comment

Choose a reason for hiding this comment

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

Looking really good, thanks for the readme update!

I added a couple of points but feel free to merge without them.

README.md Show resolved Hide resolved
README.md Outdated Show resolved Hide resolved
README.md Outdated Show resolved Hide resolved
args:
- VERSION=$VERSION
target: tutorial
profiles: ["tutorial"]
Copy link
Collaborator

Choose a reason for hiding this comment

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

Nice, didn't know this one yet. But with the demo service not having a profile, wouldn't that just launch both services if you add --profile tutorial?

Copy link
Member Author

Choose a reason for hiding this comment

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

Yes, so I'm bit of misusing the profile thing in order to get the demo ad in the Readme as catchy as possible 🙈

In the proposed setup, I'd suggest not to use --profile at all.
Instead,

  • docker compose up will run the demo service (only)
  • docker compose run --rm --service-ports tutorial will be used for the tutorial (only)

In order to avoid docker compose up --profile tutorial from launching the demo service as well, w'd have to assign a demo profile to the latter.
But, docker compose up wouldn't run anything then and we'd have to advertise the demo with docker compose up demo

Not a big deal, rather opinionated perfectionism 🤓

What do you prefer?

Copy link
Collaborator

Choose a reason for hiding this comment

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

Ah, I get it now. I like the simplified version for launching the demo but maybe we should add an explanatory comment somewhere? I guess it is a bit of a hack and without knowing the context it is not very obvious why the profiles: setting is there.

Copy link
Member Author

Choose a reason for hiding this comment

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

Alright, see 729b1fe for the docs comment.

Copy link
Collaborator

Choose a reason for hiding this comment

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

Very nice, thanks 💯

Copy link
Member Author

@orzechow orzechow Oct 31, 2024

Choose a reason for hiding this comment

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

Damn, I just realized that this affects building the images as well:
arbitration_graphs/demo ❯ docker compose build
now only builds the demo service, not the tutorial – that's a bit confusing 🤦

On the other hand, I guess the end users won't run into this (only relevant when changing the service definition) 🤷

Also we can promote using the --build flag on docker compose run

@orzechow
Copy link
Member Author

See also a45bea0 for a tiny rephrasing based on ChatGPT feedback

@ll-nick
Copy link
Collaborator

ll-nick commented Oct 31, 2024

Oh, and one more thing: The README.md inside the demo directory could then be updated to also use docker compose up to run the demo. Or do we even need the additional README file? If launching the demo is explained in the main readme and the tutorial is explained on our fancy tutorial website (#51) we could also think about just removing it.

@orzechow
Copy link
Member Author

Oh, and one more thing: The README.md inside the demo directory could then be updated to also use docker compose up to run the demo. Or do we even need the additional README file? If launching the demo is explained in the main readme and the tutorial is explained on our fancy tutorial website (#51) we could also think about just removing it.

Right, deleted with e947286

@orzechow orzechow merged commit c4bdd48 into main Oct 31, 2024
@orzechow orzechow deleted the pacman-demo branch October 31, 2024 10:17
@orzechow
Copy link
Member Author

Merged! 🚀

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