What's New in Pictorus - Q3 Wrap-Up 2023

Hello from Pictorus! Today we're excited to share updates about the latest features released since the launch of our free open beta last quarter. As always, before we dive in, we’d love to hear any feedback from our beta users. Please feel free to reach out to us at support@pictor.us or via the in-app support channel.

Python Scripting

Pictorus now supports Python scripting alongside all apps, allowing users to perform complex engineering analysis using open source libraries such as Numpy, SciPy, and SciKit in browser. Users can leverage the accessibility of Python programming to offload pre-compile calculations that declare variables for use within Pictorus apps. 

Defining Kalman Filter matrices for use within an indoor drone positioning system.

A good example use case would be a script that utilizes NumPy to calculate the matrices necessary for an algorithm (like a Kalman filter) you’d like to run in your app. All the variables returned from your python script become accessible within your app. This also makes it easy to simply copy/paste existing code from other projects.

Pictorus will still compile your code completely in Rust, this just allows you to declare variables more easily, and do some heavier mathematics leveraging Python. And for now, Python scripting is limited to pre-compile analysis. Post-run analysis and plotting/visualizations are currently under development.

You can find the Python scripting environment in the left sidebar of our UI, and also check out our video example where we use this feature in a position-estimator app.

Custom Code Blocks (Alpha)

Part of our mission for Pictorus is to enable engineers to extend the capabilities of our platform - by making our block library open source and extensible. We’ve taken a step in this direction with our custom crates feature (currently in alpha). 

0:00
/0:25

Wrapping custom Rust code into a new Block is as easy as drag-and-drop with the Custom Crates feature.

With this feature, users can write Rust libraries of their own and easily import them as custom blocks. This may be especially useful when working with widely used sensors that have existing Rust libraries. For instance, we implemented a custom crate to interface with the VL53L0x time-of-flight sensor - which has an existing, open source library we easily wrapped into a new block. 

For now, we are limiting this feature to a subset of alpha testers. Please reach out if you’re comfortable with programming in Rust and are interested in giving this feature a try!

New Blocks in the Core Library

We're always releasing new blocks to our core library (available to all), driven in large part by the requests of our users. Please reach out with any functionality you'd like to see in future releases! This quarter four new blocks made the cut:

Frequency filter

The Frequency Filter block emits either a high pass or low pass filter of the input signal, analogous to a first-order RC filter, specified by a cutoff frequency (in hertz). This first-order filter can be effective at attenuating undesirable frequencies from sensor measurements. 

Frequency filtering a sum of three sine waves to illustrate high-pass and low-pass filtering techniques.

Delay control block

The Delay Control block addresses the rapid firing of noisy input by rate limiting the output one of two ways. The Debounce method waits for the input to stop changing for delay_time seconds after before emitting True. Conversely, The Throttle method immediately emits True when the input becomes True, but then will not emit True again for at least delay_time seconds.

Debouncing and Throttling an input signal can be effective ways to prevent over-active triggering.

Sliding window block

The Sliding Window block maintains a vector queue of the last N samples of the input signal. This makes it very easy to implement a moving average of data, or perhaps a median filter.

Sliding windows act as a "First In, First Out" (FIFO) queue of recent data samples.

Vector slice

The Vector Slice block outputs a sub-matrix from within a larger matrix, given a starting row, column position and a valid output shape. This is particularly useful for extracting just a few critical elements from a larger matrix computation.

Extracting a [2,1] or [2,2] sub-matrix from a larger [3, 2] matrix is easy with slices.

Expanded JSON types for Serialization 

Our last improvement to announce pertains to vector and matrix support within JSON serialization. Previously, JSON (de)serialization blocks only accepted scalar and byte signals. Now you can include vectors and matrices in JSON as well. This allows more complex data to be sent or received via the JSON standard.

That's a wrap for today. From all of us at Pictorus, thanks for reading, and stay tuned for next quarter's updates!