{"id":5335,"library":"mxnet","title":"Apache MXNet: Ultra-scalable Deep Learning Framework","description":"Apache MXNet was an ultra-scalable deep learning framework known for its flexibility, efficiency, and multi-language support. It allowed users to mix and match imperative and symbolic programming for deep learning tasks. The project's last stable release was 1.9.1 in May 2022, and it was moved to the Apache Attic in September 2023, signifying that it is no longer actively developed or maintained.","status":"abandoned","version":"1.9.1","language":"en","source_language":"en","source_url":"https://github.com/apache/incubator-mxnet","tags":["deep learning","machine learning","neural networks","abandoned"],"install":[{"cmd":"pip install mxnet","lang":"bash","label":"CPU Version"},{"cmd":"pip install mxnet-cu112","lang":"bash","label":"GPU Version (CUDA 11.2)"},{"cmd":"pip install mxnet-cu102","lang":"bash","label":"GPU Version (CUDA 10.2)"}],"dependencies":[{"reason":"MXNet has strict and often outdated compatibility requirements with NumPy, leading to common installation and runtime errors with newer NumPy versions.","package":"numpy","optional":false}],"imports":[{"symbol":"mxnet","correct":"import mxnet as mx"},{"note":"While `import mxnet.ndarray as nd` works, the common and idiomatic way is `from mxnet import nd` or to access it via `mx.nd` after `import mxnet as mx`.","wrong":"import mxnet.ndarray as nd","symbol":"ndarray","correct":"from mxnet import nd"},{"note":"Similar to `ndarray`, `from mxnet import gluon` or accessing via `mx.gluon` after `import mxnet as mx` is the common pattern.","wrong":"import mxnet.gluon as gluon","symbol":"gluon","correct":"from mxnet import gluon"},{"symbol":"autograd","correct":"from mxnet import autograd"}],"quickstart":{"code":"import mxnet as mx\nfrom mxnet import gluon, nd\nfrom mxnet.gluon import nn\n\n# Define a simple neural network\nclass MLP(nn.Block):\n    def __init__(self, **kwargs):\n        super(MLP, self).__init__(**kwargs)\n        self.dense0 = nn.Dense(128, activation='relu')\n        self.dense1 = nn.Dense(64, activation='relu')\n        self.dense2 = nn.Dense(10)\n\n    def forward(self, x):\n        x = self.dense0(x)\n        x = self.dense1(x)\n        x = self.dense2(x)\n        return x\n\n# Create an instance of the network\nnet = MLP()\n\n# Initialize parameters\nctx = mx.cpu(0) # Or mx.gpu(0) if GPU is available and MXNet-GPU is installed\nnet.initialize(mx.init.Xavier(), ctx=ctx)\n\n# Create a dummy input (e.g., for a batch of 1 with 784 features)\ndummy_input = nd.random.uniform(shape=(1, 784), ctx=ctx)\n\n# Perform a forward pass\noutput = net(dummy_input)\nprint(f\"Network output shape: {output.shape}\")\n\n# Simple tensor operation\na = nd.ones((2, 3), ctx=ctx)\nb = a * 2\nprint(f\"Simple NDArray operation result: {b.asnumpy()}\")","lang":"python","description":"This quickstart demonstrates defining a simple Multi-Layer Perceptron (MLP) using MXNet's Gluon API, initializing its parameters, and performing a forward pass with dummy data. It also includes a basic NDArray operation. Ensure you have the correct CPU or GPU package installed for optimal performance, and select the appropriate context (CPU/GPU)."},"warnings":[{"fix":"Consider migrating to actively maintained deep learning frameworks like TensorFlow or PyTorch for ongoing development and support. For existing projects, pin to `mxnet==1.9.1` and its compatible dependencies.","message":"Apache MXNet has been moved to the Apache Attic as of September 2023 and is no longer actively developed or maintained. No new releases, features, or official support are expected.","severity":"breaking","affected_versions":"All versions post-1.9.1"},{"fix":"Install a specific, compatible NumPy version alongside MXNet. For `mxnet==1.9.1`, `pip install numpy<1.20.0` is generally advised. Consult specific installation guides or trial-and-error with older NumPy versions if issues persist.","message":"MXNet has known compatibility issues with newer versions of NumPy, often requiring older NumPy versions (e.g., `<1.20.0` or even specific versions like `1.23.5` for `1.8`) to avoid errors like `Module 'numpy' has no attribute 'bool'`.","severity":"gotcha","affected_versions":"1.x series (especially 1.9.1 with recent NumPy)"},{"fix":"Verify your CUDA Toolkit version using `nvcc --version` and install the corresponding `mxnet-cuXXX` package (e.g., `mxnet-cu112` for CUDA 11.2, `mxnet-cu102` for CUDA 10.2). If you have a newer CUDA version, you may need to downgrade your CUDA Toolkit or use the CPU-only MXNet package.","message":"GPU installations (`mxnet-cuXXX`) require strict matching of the installed CUDA Toolkit version with the MXNet package. With the project abandoned, there is no official support for recent CUDA versions (e.g., CUDA 12.x).","severity":"gotcha","affected_versions":"All GPU-enabled 1.x versions"},{"fix":"For the stable 1.9.1, existing Gluon and NDArray usage remains. If you were working with pre-2.0.0 beta features, be aware of the shift towards a more NumPy-like interface and Gluon for neural network construction. Given the project's abandonment, these 2.0.0 changes are largely theoretical for new users.","message":"The (unreleased) 2.0.0 beta versions of MXNet introduced significant API changes, deprecating legacy APIs like `Model`, `Module`, `Symbol`, and the original `NDArray` API in favor of a NumPy-compatible `np` and `npx` interface and an enhanced Gluon API.","severity":"deprecated","affected_versions":"Relevant for users attempting to use 2.0.0 beta features or migrating from older 1.x symbolic/module APIs."}],"env_vars":null,"last_verified":"2026-04-13T00:00:00.000Z","next_check":"2026-07-12T00:00:00.000Z"}