Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

arflow

Package Overview
Dependencies
Maintainers
1
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

arflow

ARFlow is a data-sharing layer that enables developer-friendly data streaming, storage, and visualization for augmented reality (AR) device data.

  • 0.3.0
  • PyPI
  • Socket score

Maintainers
1

The ARFlow Python Server

License: GPL v3 Ruff Checked with pyright

The ARFlow Python server collects streaming data from your ARFlow clients. The server is designed to be easily extensible and can be integrated with your own research prototype. Data is streamed to the rerun logger and saved to a pickle file at the end of a session, which can be visualized later using the ARFlow Player.

Installation

The ARFlow server can be simply installed via pip:

pip install arflow

Examples

Next, you may integrate ARFlow with your own research prototype via the Python API:

"""A simple example of extending the ARFlow server."""

import arflow


class CustomService(arflow.ARFlowService):
    def on_frame_received(self, frame: arflow.DataFrameRequest):
        """Called when a frame is received."""
        print("Frame received!")


def main():
    arflow.create_server(CustomService, port=8500, path_to_save="./")


if __name__ == "__main__":
    main()

Save the above code to a file, e.g., simple_server.py, and run it:

python3 simple_server.py

Once you have your server running, you can start your ARFlow clients and connect them to the server. The server will start collecting data from the clients and save it to a pickle file at the end of the session.

You can visualize the data using the ARFlow Player:

"""A simple example of replaying saved ARFlow data."""

import arflow
from .simple_server import CustomService


def main():
    """Run the example."""
    player = arflow.ARFlowPlayer(
        CustomService, frame_data_path="FRAME_DATA_PATH.pkl"
    )
    player.run()


if __name__ == "__main__":
    main()

Save the above code to a file, e.g., simple_replay.py, replace FRAME_DATA_PATH with the path to your saved pickle file, and run it:

python3 simple_replay.py

For more examples, check out the examples directory.

Contributing

We welcome contributions to ARFlow! Please refer to the CONTRIBUTING.md file for more information.

FAQs


Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc