sehHeiden

sehHeiden

I want to be able to use exla in a livebook. I want to use the livebook on linux (no problem) and windows.
The question I have is how do I install xla?
From hex/github I know, that I have to install some build tools, compiler, depencies on some older versions…
The package info also states that XLA_BUILD=true has to be set? But where do I set it? How do I make sure, that xla is only compiled on windows and not on linux? I assume have to use xla instead of exla?
I tried:

Mix.install(
  [
    {:nx, "~>0.6.1"},
    {:bumblebee, github: :"elixir-nx/bumblebee"},
    {:explorer,
     git: "https://github.com/elixir-explorer/explorer.git",
     ref: "aef274989ab490b0a392ccd19ec24b286a8cda1c",
     override: true},
    {:kino_vega_lite, "~> 0.1.7"},
    {:httpoison, "~> 1.8"},
    {:xla, "~> 0.5.1", XLA_BUILD: true},
    #{:exla, "~> 0.6.1"},
    {:adbc, "~> 0.1"}
  ],
  config: [
    nx: [default_backend: EXLA.Backend]

  ]
)

With *exla commented out or left in.

When I commented out exla I get the error that nmake is missing. I am pretty sure I installed everything. I installed bazel 6.1.2, I already got python 3.7. I installed mysys2 visual studio build tools 2019 and microsoft viusal C++ 2015-2022 Redistributable X86.

P.S.: Can XLA 0.5.1 do all the things as exla 0.6.1? I assume not.

Showing Posts 1 to 8

cmo

cmo

You either need to run that batch file from the build tools that sets up your environment (I can’t remember it’s name… vcvarsall.bat or something like that) before compiling or open the Development Console, which is a shortcut you should have been given when you installed the build tools. There are a few of them.

If you’ve installed a recent version of the build tools on an up to date Windows with Microsoft Terminal they will appear as options in there automatically.

I presume they want you to set XLA_BUILD as an environment variable.

jonatanklosko

jonatanklosko

Creator of Livebook

Hey @sehHeiden, EXLA does not support Windows at the moment. You will have a better luck using WSL, though I think then you need to install and use Livebook via CLI from within the WSL.

sehHeiden

sehHeiden OP

Thanks @jonatanklosko. I thought you would be able to do so when compiling xla yourself.
Therefore cloned xla and tried to compile it.

But there is no build in the makefile and mix compile and “.\builds\build.sh” is also not the right thing on windows^^

jonatanklosko

jonatanklosko

Creator of Livebook

exla relies on xla, but you do need both. The Makefile.win in xla is outdated, so compiling explicitly would fail, but note that exla doesn’t have Makefile.win altogether, because we dropped Windows support quite some time ago as there were issues and it was mostly holding us back. We may revisit native Windows in the future, but for now WSL is the way to go : )

sehHeiden

sehHeiden OP

Installed everything in wsl2 thanks.

steffen.haensch

steffen.haensch

The xla README currently describes the possibility to build from source under Windows. Although I followed the instructions closely and installed the necessary tools, I found out here that it is not currently supported on Windows.

The error message in xla

You can compile XLA locally by setting an environment variable: XLA_BUILD=true

also suggests that building from source is a possibility.

It would be helpful to update the README and error message to provide more clarity and guidance for Windows users, including the better alternative to use WSL.

jonatanklosko

jonatanklosko

Creator of Livebook

Hey @steffen.haensch : ) We currently don’t support Windows on EXLA, so the XLA instructions for Windows are not relevant and got outdated. So good call, I updated the README to avoid the confusion (Remove Windows instructions by jonatanklosko · Pull Request #70 · elixir-nx/xla · GitHub).

steffen.haensch

steffen.haensch

@jonatanklosko Thank you for considering my comment. Also thanks for the work you put in for the Elixir community.

— All posts loaded —

Where Next? Top

Trending in Questions Top

RSP87
I’m working on a project that simulates the bumbl example in the programming phoenix book. It acts almost like an email client. We have a...
New
nseaSeb
Hello, I know there is an approach for handling lists that allows for optimized traversal, but I can’t recall the specific method (somet...
New
RemyXRenard
I’m seeing that a list inside a Kino.DataTable will be interpreted as a charlist, even if the Kino.configure() is set to charlists: :as_l...
New
velrest
So my question is quite simple and i have found no conclusive answer on forum, google or AI. Should we use :erlang.float for Integer to ...
New
brecabral
Documentation While reading the Scoped Routes section, I noticed that the documentation currently refers to a problem without explainin...
New
samoloth
Hi, I’ve just set up an application with ash_authentication. There is only magic link strategy for now, so there is no confirmation add o...
New
FlyingNoodle
If a change or preparation module uses Ash.Changeset.get_argument/2 or Ash.Query.get_argument/2 (or any of the other get_argument functio...
New

Other Trending Topics Top

mudasobwa
I am happy to introduce the very α version of the new programming language compiled to BEAM. Welcome Cure. It has literally three kille...
New
marciok
Hi there! We created Gust: A task orchestrator inspired by Airflow. For those who have never heard about Aiflow, it’s a Python-based wor...
New
jimsynz
Beam Bots (or just BB for short) is a framework for building fault-tolerant robotics applications in Elixir using familiar OTP patterns. ...
New
Dmk
Xamal is a deployment tool for Elixir apps that deploys native releases to bare metal servers over SSH. It’s a port of GitHub - basecamp/...
New
netoum
Corex is an accessible, unstyled UI component library for Phoenix that integrates Zag.js state machines using Vanilla JavaScript and Live...
New
webofbits
With AI doing more of the implementation work, I’ve been wondering how much coding I should deliberately keep doing myself. My main conc...
#ai
New

We're in Beta

About us Mission Statement

Options

Thread Display Mode




Thread Preview

Skip Thread Previews