The Elixir team is pushing the numerical computation project forward and planning other additions to machine learning • DEVCLASS

After working for about 14 months, the developers of the Nx Multidimensional Tensor Library decided to cut their first official release and share v0.1 with the Elixir ecosystem in the broad sense. Nx developer and Elixir creator José Valim also took the opportunity to give a brief overview of what the future holds for those looking to use the programming language for machine learning.

Prior to putting his efforts into Elixir, Valim was best known as a member of the core team behind the Ruby on Rails web application framework. He was there confronted with increased demand for creating concurrent applications, which sparked its interest in multi-core software. In 2011, Valim decided to tackle the problem by starting work on Elixir, which he described as a “modern approach to programming for the Erlang virtual machine” and a tool for building scalable, fault-tolerant applications. and maintainable. The first official release followed in 2012.

Although Elixir does not make the top of programming language lists after its first decade, it has been chosen for various web applications based on its delivery guarantees and concurrency features. Prominent examples are the basic services of the Discord communication platform and PagerDuty service for scheduling notifications.

Now available, Nx represents a first step towards what Valim calls the digital elixir, an initiative hoping to satisfy the growing interest in machine learning and data analysis by offering corresponding tools. Besides Nx, the effort saw the component of Elixir neural networks Axon, the data frameworks project explorer and scientific dataset normalization tool scidata come to be.

While other language teams decided to add Python bindings to their creation to support the ML use case, the developers of Elixir took the path of their own foundational project to leverage the potential of Erlang VM Elixir executions and offer an alternative platform for new developments.

Nx mainly promises to provide a collection of functions and data types for numerical computation, as well as compilers that allow their efficient use on CPUs and GPUs. Its main feature is a subset of Elixir called numeric definitions (defn) which is tuned for numerical computation and allows “highly optimized code to be executed on the CPU, GPU or even Cloud TPUs” when compiled. The numerical definitions also serve as the basis for Axon and help the project to realize things like convolutional, generative, structured and vision-related neural networks.

Looking ahead to version 0.1, Nx has learned to work with while loops to support recurring patterns like those used in speech recognition in the future, and has become familiar with numeric definitions as well as capabilities. streaming data. The latter is useful when implementing distributed learning, something that Valim and Co plan to look at somewhere along the line, and inference among others.

Nx 0.1 is also equipped with an Nx.LinAlg module, which contains an initial set of linear algebra functions to support models based on matrix factorization. He’ll surely see more additions in the coming months, however, Valim’s plans for Nx currently focus mostly on more important things. Among other work items, it provides for the implementation of a checkpoint for the library’s automatic differentiation system to reduce memory usage when training large models.

To help users switch to Elixir for their machine learning projects, his team is also investigating the integration between the ONNX and Axon model interchange format, which would make it easier to use already trained models and offer Explorer bindings. precompiled. A desktop version of the Elixir Livebook codebook, on the other hand, should provide developers who want to try Elixir first with an easier way to get started.

Comments are closed.