Thank you, so I'm Louie, I'm walking at SNSF on the project OSD.
It means open source railway designer and I will present the integration of NGE and let's
take it out with just had a presentation about it in OSD.
Edron told you about about, okay, Edron told you some things about the macroscopic
level of the tail and at OSD we walk at a microscopic level of detail, we'll see how we do that.
To make short OSD is an open source software that does transformation and helps design
timetables that finally guide railway evolution and I recorded the short video if it's
walking. Yes, to show you how OSD works, so I open the test scenario and I have on the
left my list of train with the departure times and there are a lot of times and the rolling
stocks are concerned and on the right I have more details, diagrams and analytics but this is not
really important today and here we can see the itinerary of this train, for instance, on the map
that we use for this scenario and we can see a lot of things here, the signals but also
hidden, the electrification, the tracks, the blocks, the main things, yes, the sets and each train of
this list is simulated on this microscopic infrastructure and we also can see if there is some
conflicts in between the trains and what we can do is to visualize this timetable with another
tool. So what you need to know is that the squares are the nodes that it represents the
train stations and the lines, the trains of our timetable, we can see the departure times and
a lot of times each node, the running time in between and we can navigate through it, we can also
edit a train for our timetable on this tool and it changes synchronizes automatically.
And this view is very important because it makes it easy to compare a transport plane and it
can quickly analyze the performance of timetable and so this is not surprised, it was actually
two softwares, one embedded in another and I will explain you how we did it, but first I will
present briefly our CD, then NG even though we just had a presentation about it and spend some time
for the design of the solution. So our CD we have many purposes and one of the main one is to
reduce our dependence for the software market, you just mentioned via a tool and these
elements that we aim to replace them with our free and open source software. We also work on the
standardization of the tools of this industry because it can make it easier to work at the
international, for instance, will also develop reasonable bricks not only for the railway industry
but for other domains we try to be agnostic and for that we are the first hosted project of
open rail association. And we are around 45 full-time person walking at S&CF on this project
and this is very useful because we directly benefit from the insights of the person actually using
our tools, I mean this kind of tool which is not always the case for software vendors.
And NG, so in that's graphic editor you just had a presentation. In brief it's a very long term
transport plan, transport plan designer that produces network graphic or in that's graphic
in German and this is interesting to notice that they split their project into repositories
one for the front end and one for the back end. And how did we manage to integrate
NGF editor in OSID? We had a few constraints or guidelines, do not break NGE.
Evolvated our needs and capacity because we have limited time. We want to think reasonable
not only for our own use but for others and it has to be easy to maintain and get up to date.
So how to make NGE usable? So for the back end we've seen that we have similar technologies
but we are not sure to consider this option because we want to keep our stack clean and simple
I mean try. And for the front end the design of NGE has NGE has been designed for
relying almost fully on its front end. So the front end is very powerful and the back end actually
is only used for persistence, the thing that we already have at OSID. So what if we can use
only the front end of NGE and integrate it in OSID, like a front end package or something and make
communication with it. So this feature didn't exist to just get the front end and with the
refers to a refactoring NGE as separate web component but it was too much time. And we thought about
another option and refactoring some code NGE to make it able to run without back end. It's
actually the demo you just seen before. It's based on that. So we developed a standalone mode
that runs without back end and we published a build of this version on NPM that we can use
any other JavaScript framework. So that's nice. And even if it can run alone it does not communicate
with anything except itself. So we had to figure out. And we decided to go through custom elements
because NGE was aimed to be embedded in another software. So we could just create
a custom element on NGE side and communicate with it using the element accessible from the
outer of NGE. And this way we could send that inside NGE from the outer of it. We'll see after
how it exactly works. And for us, we instantiate it in an iFrame. And last because we have
specific needs we decided to fork the repository of NGE but just for minor changes that we
cannot push on the main. And we tried to reduce the number of this hacks. It's mainly to hide
some elements or to misuse others that we don't know how to use it. And now we'll see how
we constricted it. So first we are based on OSAD which has a complex stack because it's
designed to be scalable and some other things. But we will reduce this cup on the back end and the
front end. For the back end we have a WordPress tool for the base and rest as a middleware and
other things for the simulations or the the type of lines. And the front end is written in type
script and NGE. So now we can use what we said earlier. The NGE standalone version.
That's now runs inside OSAD but cannot communicate with anything. So this is nice because
we succeeded to be agnostic of the different of the JavaScript frameworks.
After some digging we found that the central element of object of NGE is an end graphic detail.
In this object this object digs. It is thanks to this object that NGE displays what it displays
the nodes, the tryanons and stuff. So we need to find a way to put data in this object.
And in Angular there is a decorator named input. That is a property bound to the element to
the property and that automatically listens to changes on this element and updated that the data
of the data property from the properties value. And from that we can set new data in the
net graphic detail and from also from the outer. Because the the dump property is not accessible
from the outer here it's called SBB root and we only need to transform our timetable
into NGE compatible object. Here it's nodes and tryanons. And then that's it. We put data
our data from our timetable in NGE and it's automatically updating. So what we need to do now
is the run trip to send data out of NGE. So there is a lot of objects handles in NGE,
tryanons, nodes, labels and stuff but it's not important. What's important is that whenever
we implemented a concept operations whenever these objects are updated, created or deleted
we send a message through event emitters, standardized as operations into a node put
a decorator from Angular which changed the value of the dump property operations.
So from the outer of it on the oversight side we can just listen to the changes of this dump
property. NGE almost done. What we did already was to send the updates of our timetable
whenever our timetable was changing. So we can just do the same thing and just match the events
to our Saturday compatible events and that's it. We have a closed system NGE is displaying
our data and is sending back the modification that we are doing in it. So that's pretty nice
and not even very complicated. We designed NGE standalone to be able to process that kind of
magic. So we are not the only user of this. So that was it for the solution and I will briefly
finish with how we do we cooperate. So OECD is a project open source from SNCF and NGE from
SBB. We are both part of OpenRL Association which is nice and currently OECD is using NGE so that's nice
but what's really nice is that we made two open source project work together from big companies.
And because we use their software we try to contribute to their project,
not only because we have slightly bigger task force but because we like to contribute that way.
So we developed a few features. We are active on their repositories and also we did some
events together. For instance, the Thailand Arc, it's another hacker event organized by SBB
or the Austrian and the Swiss and the German railway company. We worked there together with
Adrian last year. So why not you? And I'm done with that if you have any question. We'd be glad to
answer. If there is no question, that's fine. I was clear then.
Why did we not use an I-frame and not directly imported application. Because it was easier for us
to communicate to instantiate like it was easier for us to instantiate it in an I-frame
because we could just instantiate NGE and that's all. It's separated. It's easier.
Is it difficult to extract data with the same thing the problem?
Good question. Because we ran directly the application at the same server. We don't have the
kind of issue about security issues using I-frame.
Yes.
Sorry?
Is or should the NGE deployable?
Yes. It's already deployed internally at SNCF. It's working. You can download the project
on GitHub and work with it. We are working on a public demonstration environment but it requires
more data than the Microsoft speakers. So we are currently working in it and in the few months
we will have such an environment for demonstration.
Are there contributors outside of SNCF or could I use this project?
Yes. Only a few for now. Maybe mainly because it's a very complex project but we are keen to
to embark anyone that wants to contribute. We had many contributions but not for big features.
Yet.
Okay, thanks a lot. I think we have to change.