You can not select more than 25 topics Topics must start with a chinese character,a letter or number, can include dashes ('-') and can be up to 35 characters long.

run.rs 641 B

123456789101112131415161718192021222324
  1. use eyre::WrapErr;
  2. use std::path::Path;
  3. #[tokio::main]
  4. async fn main() -> eyre::Result<()> {
  5. let root = Path::new(env!("CARGO_MANIFEST_DIR"));
  6. std::env::set_current_dir(root.join(file!()).parent().unwrap())
  7. .wrap_err("failed to set working dir")?;
  8. let dataflow = Path::new("dataflow.yml");
  9. run_dataflow(dataflow).await?;
  10. Ok(())
  11. }
  12. async fn run_dataflow(dataflow: &Path) -> eyre::Result<()> {
  13. let mut cmd = tokio::process::Command::new("dora-daemon");
  14. cmd.arg("--run-dataflow").arg(dataflow);
  15. if !cmd.status().await?.success() {
  16. eyre::bail!("failed to build dataflow");
  17. };
  18. Ok(())
  19. }

DORA (Dataflow-Oriented Robotic Architecture) is middleware designed to streamline and simplify the creation of AI-based robotic applications. It offers low latency, composable, and distributed datafl