In November 2020 Microsoft shipped .NET 5. This is the first of two major steps in .NET unification which will create opportunities for vision system providers to reduce lead time and cost whilst improving quality. This article briefly discusses the history of .NET and describes the plans for 2021.
The background to .NET
The first incarnation of .NET was the .NET Framework released by Microsoft in 2002. This was a development and runtime environment for Windows based desktop and web applications. Throughout the 2000s, Microsoft’s development tools were entirely Windows focused. Developers targeting non-Windows environments, notably Linux and macOS, turned to Java as the leading cross-platform application development stack. In 2016, Microsoft made a radical change by releasing the first version of .NET Core. The primary objective of .NET Core was to provide a cross-platform implementation of .NET Framework, allowing developers to build .NET applications for Linux, macOS and Windows with a common set of tools. The .NET Core project has largely achieved its cross-platform goal – the exception is the user interface tools (Windows Forms and Windows Presentation Foundation), which are still only available for Windows applications.
A common source of confusion in .NET terminology is the term .NET Standard. With the introduction of .NET Core, Microsoft created a formal specification to define the common libraries used across all .NET implementations (known as the Base Class Libraries). This specification became known as .NET Standard and can be targeted for building class libraries which support .NET Framework and .NET Core.
.NET 5 and MAUI
Although .NET Core has been well adopted for web applications, developers building desktop applications have largely continued to use the traditional .NET Framework stack. The primary reason for this is that .NET Core has not yet provided a cross-platform user interface solution, limiting desktop development to Windows. A key observation in the release of .NET 5 is the name: Microsoft have dropped the words “Core” and “Framework” and indicated that this is the main implementation of .NET going forward. Additionally, Microsoft have announced that some older technologies such as Web Forms will not be ported from .NET Framework to .NET 5, strengthening the message that they want developers to adopt the new cross-platform tools.
.NET 5 is paving the way for the next major milestone in Microsoft’s “journey to one .NET”. When .NET 6 ships in late 2021, it will contain the first implementation of MAUI (Multi-platform App UI). The intent of MAUI is to complete the cross-platform objective started with .NET Core by providing a user interface development solution for all operating systems. Even Xamarin, the .NET smartphone development toolset, will be folded into MAUI. This means that .NET 6 will provide the ability to code once and run anywhere, regardless of operating system and CPU architecture.
The relevance for Vision Systems
With the introduction of Deep Learning in computer vision, cross-platform development has become more important. Much of the open source community operates with Linux for Deep Learning development, for example NVIDIA’s Jetson products and Isaac SDK. Up until now this has created a challenge for companies developing vision systems due to the lack of a truly cross-platform development toolset, resulting in completely separate code for Windows and Linux. The Qt toolkit has been a contender however the API is written in C++, making application developing time-consuming and harder to hire developers for. Python is cross-platform, and is great for rapid prototyping however there are significant speed concerns when developing real-time vision applications. The introduction of MAUI with .NET 6 is therefore significant as it completes the cross-platform implementation of .NET, allowing code to be developed in high-level languages (C#, F# and VB) and deployed to any device.
A key enabler for using the cross-platform implementation of .NET for vision is having image processing libraries available which support .NET cross-platform bindings. At the time of writing, Matrox have confirmed that their leading product MIL will support .NET 5 later in 2021. MVTec Halcon already supports .NET Core therefore we can assume that MVTec will support the unified version of .NET in the future. Cognex VisionPro only runs on Windows therefore Cognex will most likely remain with .NET Framework for now.
Conclusion
The unification occurring in .NET 5 and the forthcoming cross-platform user interface framework planned for .NET 6 allows vision application code to be written once and ran on any device. At Agmanic Vision, this enables us to shorten development lead times and costs by reusing the same code between Windows and Linux based applications.