Get the Monday email →
Loading player…

Watch Your Models Learn: Real-Time AI/ML Experiments with Visdom

DevconSun, Nov 15, 2026, 12:00 AM

Transcript

[music] [music]

Um yeah, every Hello everyone. Um nice to see a few people. Also, I don't see you actually because it's so bright here. Um I'm Norbert Brainin. Um I work at archive.

Um and I'm also well doing open source projects with FOSSASIA and some others, too, since many years. Um you we have heard a bit about Wisdom already. Uh Who has used Wisdom before? Three. Oh, that needs to increase, I see.

Um we will have a lot of talks about Wisdom actually following introducing uh several details, uh new features we have introduced over the last 1 and 1/2 to 2 years. Um I I want to pick into a very small topic, namely how how we can use Wisdom for AI for machine learning in the general case. Um Who has done some machine learning? No, all hands up, right? No.

Um who who has trained their own model? Yes, a few people. What did you use? What frameworks?

PyTorch.

PyTorch. Anything else?

TensorFlow.

Yes. Anything else? Man, the biggest Python framework, scikit-learn, for example. Anyway, we will come to this. Yeah, so it's about how to link those frameworks with Wisdom.

Yeah, so it's not a general introduction to Wisdom nor to the frameworks. It's just um to this framework. A bit about myself. Um I'm a mathematician, a more general logician. Uh so, I do very strange stuff.

Um it's proof theory, if you ever heard about this. Uh I have worked more than 25 years in open source projects. Uh the biggest uh Well, now many of them, Um I have worked more than 25 years in academia, various in universities like the University of Technology in Vienna, then in Italy, and then for nearly 10 years in Japan at the JAIST. Um Then in several companies in Japan, Axelia, Fujitsu Research, and Mercari, and currently I'm with Archive. Who knows Archive?

Okay, everyone who is in computer science and does not know Archive should now hide under a chair. Okay? Archive is the biggest preprint server. All your research papers for your work are on there. It's up there since 30 years, but that's not the topic of today.

So, what is So, Wisdom, we have seen Wisdom in action for a few talks before. We will see them follow up now. So, how we can we plug this into machine learning? So, machine learning frameworks, I'm I asked you a few more are mentioned here like Python. Yeah?

Also NumPy. I mean, it's not directly, but it does computation on the back. PyTorch was mentioned, TensorFlow, Keras. Keras um yeah, it was You know, a side story, when I first used TensorFlow, it was TensorFlow 1 without Keras, and you had to write the whole graph by yourself. That was super complicated.

I'm more than happy that we have a very nice uh um frameworks now. Now, if you train them, I mean, if you have trained your models, you know that this is a time-consuming and sometimes painful process that you have to repeat again and again. And you would like to somehow monitor. You want to see how good it works. You might want to stop if it doesn't behave well, if the training just goes sideways.

So, that is [snorts] where we plugged in the Wisdom, connecting Wisdom between the Python code from the ML framework and display the results online updated in the browser. So, it's very easy. You just In principle, what you have you have your your your computer or if you have your, I don't know, super thousands of NVIDIAs GPUs running somewhere in parallel crashing the newest LLM model. Um and at the same time you can look to Visdom and that plots automatically to your browser where you're sitting on your desktop and watching at how everything changes. So, um So, the as I say, this is not an introduction to Visdom.

So, you that is the minimal of what you can do in Visdom. Of course, you have to actually start the Visdom server and so, but what I want to say here is it's like that what you send there is immediately plotted on your on your screen on your browser in your browser. Um more interesting is uh actual training. So, I hope this video works. So, what you plug in here, I mean, it's all very trivial examples.

It's just the the training on the digits everyone knows, right? I I didn't want to make a super involved examples. So, what you see here, you see the the Oh. Oh, that should have stopped before. Yeah.

So, you see here that it starts just a training program. It It's a trivial really small training program. And in addition to just training, it also connects to the Visdom server. So, we you have a Visdom server somewhere running. In this case, it's just running on my own machine.

And it sends for each step the loss value and at the same time it is plotted there right in the browser. Of course, this is a cut-together video. So, this is your terminal, and then the the right part is from the browser. So. So, um but last, this is not everything, right?

I mean, all these metrics are nice. Um experiments produce much more. Um what could it be typically? What What what what what if you if you train and test uh you know, cross-validation and this kind of things, what would be a typical thing that you would look into in your model? Any ideas?

Yeah, confusion matrix, heat burn, all kind of images are created informing. So, for example, I created a captureless capture um by just Yeah, um So, we couldn't use Google capture because back then it didn't work. So, I collected just the information about the mouse movement, keyboard movement, everything, and put this into a a model to train and to detect bots. And then, I have like I had actually 20 models versus 20 models, and then compared them against each other, which one was the best against each other's test cases, training cases. So, there are a lot of things when you actually train a model.

There are a lot of artifacts generated. And artifacts could be like images, but heat maps, just text, graphics, tables, long lists of of stuff. Um And this is something that um uh Wisdom also supports. So, the simplest thing what we have seen before, you just plot the mat a matrix. Um oh, it's quick quick.

So, a matrix was plotted before. Here here you have a confusion matrix, simple lists of stuff. Uh embeddings, all of this kind of stuff is supported out of the box from Wisdom. Um, you can whatever helps you determine whether your model behaves well or not, right? So, that is the aim.

Um, so, if you up to now we have seen just normal um, well, Wisdom run. If you do more, I mean, complicated stuff, many people reach out to PyTorch because it's one of the most easy to handle, let's put I would say it's easy to write uh, a good architecture in PyTorch, yeah. Um, so, this is a if you want to do this is PyTorch, there is no difference, right? You have the PyTorch to Wisdom is the absolute same, yeah. In PyTorch you do forward training, backward training, and between you compute the loss, and then you just send this off to Wisdom.

It's, yeah, optimizer step it's out. You could in principle collect metrics at each and every step, uh, send it off to uh, Wisdom to for actual plotting. I have here an example that plots uh, the validation loss, the training loss, and validation accuracy over the time. And at the same time, for example, on the left part down here it shows the current batch. So, this gives you a quite nice view on what is going on in your training.

Um, and yeah, it would that is what I say we want to reduce the time. Um, typical example, if if for example, the the model wasn't that good or something bad happened, you would see validation accuracy collapse very soon. You don't want to run through 10,000 of batches just uh, just realizing afterwards that that that was a bad model. Um, it's also it's we don't force you to use PyTorch. As I mentioned before, there are a lot of libraries, frameworks we support.

So, any all of these libraries here you probably have heard uh, PyTorch, PyTorch Lightning, TensorFlow with Keras backend, scikit-learn. This is for more classical machine learning problems, and XGBoost, also very popular for many callbacks. All of them can do practically the same. You hook into the logging of the the different frameworks and send the results off to Wisdom, and Wisdom then plots it. So, let's go through a few examples.

So, the PyTorch Lightning log Oops. Okay. What's this? Oh, yeah. The PyTorch Lightning logger, yeah, you just import it and and stuff, and then it's just PyTorch doing uh stuff.

Here you see on the left top, also the Too fast. Okay. Yeah, same with Keras. Keras is also TensorFlow and Keras XGBoost autolog. It The the code remains more or less the same all the time.

You just throw in the you hook. There's slight difference. I I don't go into details the how to hook them in. That is due to the libraries to the frameworks themselves, but generally, you just hook in an extra call to the autologger. Okay.

Now you have one run finished. Um What do you do with this one run? Are you happy? No, normally not. Normally, experiments take much more than one run because, yeah, well, the this is part of hyperparameter tuning.

Yeah, you know, if you do an embedding, if you do a clustering, you don't know how in how many elements you are cluster, um architectural changes, so all kind of stuff. So, what is the reality is is that it that you run a lot of times. As I said before, I I trained for this one model, I trained 20 models and then did a lot of runs, cross-validation between the models. And then you have to keep track on all these data, right? This is a problem back then without wisdom.

I had to do this manually. I I made a spreadsheet and typed in every values and and kept it there. It's not nice. So, um what we can in total here is so, we have much more for every run, right? You want to remember in a few weeks down the line, you look back at the experiments and have to report to your whatever uh executive committee or whatever what has you done.

You have to report so, how did you train this? Or you pass it on. I mean, this is something that is quite

[sighs]

often uh a real problem. People generate uh machine learning models in production and then they change job and then the next while person is unfortunately just taken because there's no proper documentation about what are the values that went into training the model and you have to retrain, right? Typically, parameters, hyperparameters, everything that influences the model model directly, metrics from the evaluation run, tags like what you did special in the sense, the status, is it rejected, accepted, whatever. So, you what you really want is that you also keep track of these experiments and we have you covered here, too. So, um Oops.

Yeah. So,

[groaning]

Okay. So, here is a typical a dashboard from your experiments. Um you can filter on the left side to according you have you can sort by whatever parameter you have in there. You can hide stuff. You have tags of where where this finished or running.

Um you can plot and compare them. Um that is a super useful uh feature when you cross compare how different models develop in different areas because they will not be good in everything. So, all these features are now built into wisdom. So, you can train your your you can explore, so to say the hyperparameter space, the experiment space more confidently, collect the results, and then yeah, bring them together for a good decision. Another thing is marking up my time is running out, sorry.

So, you can actually also mark up in the browser very easily some strange points to remember. This is also saved, and you can remember it when you look back a few weeks later what I actually happened there. So, that is a very easy markup. I think we will have a talk about this. Last but not least, in 3 seconds, um So, all of this is there is one thing you don't want your training to be slowed down, right?

Training is time intensive, and if your visualization also takes a lot of time, then two processes compete for resources, and that is not good. So, that's the reason we have an async version of the whole stuff now. So, it runs off the main the main thread on where all your rest is, and can the training can run in parallel. So, here is a a compute So, a compute heavy train, I mean the training, but also the display is heavy because it tries to generate here the area that separates the two colors, and that's quite heavy to compute, and you don't want it to stop the rest here. So, that is what also in the today released version we have the async now.

So, all in all, what we try here is to keep it simple for everyone, right? We don't want to change your training. You have those who have trained on machine learning and everything have a lot of experience. They know how everything goes. We don't want to change how you're doing this.

[gasps]

We just want to a minimal API that is compatible and also in the dialect of the original framework that you call out to wisdom, preferably in an asynchronous way that your main training actually runs as fast as it should be. And yeah, so that is our idea. Uh very easy to get. Last but not least, I think I have to mention this because that cannot be stated it you can run the server on your machine, on your computing. You don't have to hand over your data to any company that is outside your country or outside your continent or whatever.

You are the all whole only proprietor of the data. So, that is a thing that especially for medical applications, pharmaceutical where you have to be sure that your data is not leaked out somewhere is important. Wisdom allows you to run it locally on whatever you provide. Um so, to sum it up, don't just wait for the end result because that can be a pain. Especially with the scarcity of GPUs, it's getting harder.

Run the tests and observe at the same time your experiments to get better training. Um yeah, that's all. Thanks for your attention and sorry for the time over. If you want to contact me, the left is LinkedIn and the other is my email. Thanks.

Automatic transcript — names and jargon may be misspelled.