Get the Monday email →
Loading player…

Rebuilding Visdom AI Visualizations in Five Layers

DevconSun, Nov 15, 2026, 12:00 AM

Transcript

[music]

So, thank you so much for a nice introduction, Annika. So, good afternoon everyone. Myself Mani Khajuria. I am from NIT Jalandhar. I am working with Force Asia with the team Wisdom.

So, most of you working with machine learning experiments might have encountered Wisdom. So, it's basically like you call something like wiz.line and you got some of the plots on the browser while the model is training, right? So, when I was working in Wisdom, so I encountered a problem. So, it was basically what if we are not dealing with one experiment?

What if we are dealing with multiple experiments? In that case, how we can compare experiments? How can get metadata for the experiments? How we are going to say that this experiment is different from that another experiment? So, for that team Wisdom was working for the past few months and what we have come up with is the five engineering layers, which is a talk of mine today.

And there are some also optimizations which I will be talking about. So, let's start. So, yeah. So, first of all, let's discuss what was the problem. So, first problem which we encounter was there was no search functionality in the Wisdom for searching the experiments.

The second was if you see, we can't compare some experiments. We since we don't have metadata in the experiments itself, then we can say that the performance of Wisdom since there are a lot of synchronous tasks being done. So, it was getting a bunch of overhead. And then we don't have tests at all. But it was causing if someone changes something, so we can't say that it's reliable or not, right?

Oh. Uh sorry. Okay, so uh uh sorry for interruption. Yeah, so let's before beginning something, so first we measured some metrics also what was happening in Wisdom. So you can see previously what was happening was Wisdom was plotting 198 plots per second.

Import Wisdom was taking around 1.96 seconds and while we are appending 1.2 a 20,000 point plane, it was taking around 30 milliseconds and there were no Python backend test at all, right? So this is what Wisdom team measured and would will help us to improve Wisdom in incremented layers. So then what we introduced was five engineering layers which are has on the screen.

So first we have data abstraction layer. So basically it's what it does is um separates your application logic from the storage logic. Then we have experiment layer which introduced some experiment metadata in the experiment itself. Then we have H parameter dashboard. So what it does is provide a dedicated UI dashboard in the front end itself.

Then we'll fill the async IO layer. So it makes the whole Wisdom server asynchronous and async client. And also we have testing layer where we introduce a lot of tests. Let's talk about each of the layers one by one. So let's start with the data abstraction layer.

So eventually what it was what we introduced was a new data abstract class data store which provide different functionalities like save environment, load environment, delete environment and list environment. Also we introduced JSON store which help us to preserve the wisdom implementation of the JSON format. So, lot of you might be thinking why it's being needed at all. So, basically first of all when you are dealing with application, it doesn't need to know how data is being stored in user's directory, how it's being stored and the second thing you it gave us a future perspective for us to how we are going other kind of database, whether it's relational database, non-relation database which we want in future itself. Then let's talk about the second layer.

It's search experiment layer. So, now we have introduced in wisdom. You can say the search functionalities. We also enable users to log metadata like parameters, metrics and status tags. Now users can log that.

We also provide search and you can say compare functionality. So, what search functionality gives? It's lets you search different kinds of experiment. You do something like you can say this dot search experiment with this learning rate and this log. So, all of that will be shown and in compare you took two or three experiments, check what is different between, check what is similar between them, what is the differing and other stuff.

We also introduce a query parameter. You can say the it's not a query parameter, it's a query parser. So, it's a recursive tokenizer and an abstract syntax tree for that search stuff. So, this is what we introduced the wisdom team for the search layer. Then we have a third layer which our main focus was for this past few months.

So, it was hyperparameter layer. So, it's a being a dedicated UI you can see on the screen itself. So, what it provides a different runs in rows and the matrix parameters in the columns and the values. We also provided a search sidebar a filter where the user can filter based on his choice. He wants this parameter or that matrix, this range.

So whatever he wants will be available on the UI itself. Uh, then in the search hyperparameter dashboard itself, we have also introduced some of the plots in the dashboard itself. So first we can see parallel coordinate system where user can you can say select different kind of parameters and hyperparameters and matrix whatever he wants and he can see in one go the parallel plotting of the different experiments, how they are increasing or how they are decreasing, how being related to. Then we have scatter matrix you can see here. So it basically lets you define the relationship between one of the two experiments, how the experiment is being related to experiment two or the experiment three.

Also we introduce metric plots. So basically when we have different metric logging. So the researchers and others people can just see through it how you can say the graph decreases, increases, how the metric log is performing, how the model is being used and how the model is performing, whether the metrics are going right or not, whether the model training is right or not. So that is what in the metric history. Then moving to the next part, we also introduced the compare plot in the hyperparameter dashboard itself.

So basically here we give the user to select some of the experiments and in that experiments what user can do is select them and they get a complete dedicated dashboard in which he can see what is different in it, what is similar to it. So he can basically analyze what is identical between them in the UI itself, what is different between them in the UI. So that is what is being seen here in the compare dash plots in the hyper environment complete dashboard. So then moving to the next what wisdom team was working for the past months was fourth layer which was async IO. So since what was the problem first of all?

So the problem was since we have synchronous wisdom. So even when request goes on and it's being stuck in the disk task disk operation. So another five users come. So they won't be able to plot the data until unless the request is done. So that is what we don't want.

So what we do is like separate the storage thread from the request thread and what it does is pretty nice stuff. So it is like now since one request is stuck in the IO now the other request can be handled and there are can be parallel plotting of the plots and so that one user can doesn't need to we can say the stop or he wants to rest for the other users to for the completion request. Then we can say we have also introduced graceful shutdown of the server itself where we introduced how rather than just completely shut down the server without completing the experiment or plots. Now it's being done gracefully when we even press control C the flashes your run. Then moving to the next part.

So since we have introduced a sync wisdom server, we have also introduced a sync client. So a sync client so what we wisdom team did we didn't want that we want to maintain two clients at all. So what we do is we make an async wisdom bridge class. So it's basically a bridge class between the synchronous client rather than plotting you say 40 plots at the writing the whole 14 plotting methods and we just make a sync wisdom class and yeah and also we don't mean need to maintain it synchronously with the other client. So that is what is being handled.

So now let's talk about what are the results of all these optimizations and all these layers we introduced. So you can see on the screen previously wisdom was plotting 190 plots per second but what it does now it is serial cost wisdom is plotting 235 plots per second but if we use the functionality of pre-flight turn it's 304 plots per second which is 1.5 x of the previous version and if we use a sync wisdom and concurrent eight concurrent threads so it's using 410 plots per second which is approximately 2x the speed. So it's the major optimization I would say then moving to the next last layer. So it was test layer.

So since wisdom doesn't have test at all now we introduce a bunch of test. So right now we have around 3126 test with 72 files 84% coverage and we also while we were dealing with this test we find some bugs and we just solve those works in the same PR. So this is what the testing layers works for then so after the five layers what we guys notice that might the synchronous might help in the concurrency task but it doesn't help at the CPU optimization task. So what we do again did some benchmarking harness and we did encountered what are the performance issues and there what we discovered that there were multiple times where the JSON encoding was doing again and again there was you know there was not we don't need defeating the comparison again and and there was also uh other stuff like sanitizing the payload again and again, broadcasting the same data for each client again and again. So that is what is being optimized in this layer and there are a lot of other optimizations which were being done.

So after the optimization itself, so what is now the current condition of the wisdom? So you can see in the screen previously if I send a 20,000 point plane to four clients, it was taking around 124 second milliseconds, but now it's taking 30 milliseconds. A pending one point to a 20,000 point line plot previously was taking around 30 milliseconds, but now it's being taking point it's like 19 microseconds while logging one log observation to a 20,000 step run. It was previously taking 16 millisecond, but now it's taking 0.28 millisecond and opening a 32 dashboard tabs it there was taking around 496 encodes, but now it's has become 31 encodes at all and the major optimizer I would say previously the wisdom which was importing wisdom was taking around 1.

96 seconds, but now it's taking 0.18 seconds only. So this is the optimization which we have achieved by introducing these five layers and the CPU optimization task. And so I think so there are some slides issue. Yeah, so at end I would like to say we have worked on the database action layer.

We have worked on search and the comparison layer. We have worked on hyperparameter dashboards. We have also worked on a sync server and the sync client, also on the testing part, also on the performance engineering part of the CPU optimization. There is a lot more to explore in wisdom. If you want to see how data storage shared classes are being stored and how we are doing the smart experiment recommendations and also a lot of optimizations you can see.

Please try wisdom I would say. Try to contribute in it and tell us what you think about it. This is what I have for today talk. Thank you everyone for this

Automatic transcript — names and jargon may be misspelled.