{% extends "layout.html" %}
{% set title = 'JAX-sklearn: JAX-Accelerated Machine Learning in Python' %}

{% if is_devrelease|tobool %}
  {%- set contributing_link = pathto("developers/contributing") %}
  {%- set contributing_attrs = "" %}
{%- else %}
  {%- set contributing_link = "https://jax-sklearn.org/dev/developers/contributing.html" %}
  {%- set contributing_attrs = 'target="_blank" rel="noopener noreferrer"' %}
{%- endif %}

{%- import "static/webpack-macros.html" as _webpack with context %}

{% block docs_navbar %}
{{ super() }}

<div class="container-fluid sk-landing-top-bar py-4">
  <div class="container sk-landing-container">
    <div class="row">
      <div class="col-md-6 mb-3 mb-md-0">
        <h1 class="sk-landing-header font-monospace">JAX-sklearn</h1>
        <h4 class="sk-landing-subheader fst-italic mb-3">JAX-Accelerated Machine Learning in Python</h4>
        <div class="mb-3">
          <span class="badge bg-success me-2">🚀 5x+ Faster</span>
          <span class="badge bg-info me-2">🖥️ Multi-Hardware</span>
          <span class="badge bg-warning text-dark me-2">🔄 Drop-in Replacement</span>
        </div>
        <a class="btn sk-btn-orange mb-1" href="{{ pathto('getting_started') }}" role="button">🚀 Quick Start</a>
        <a class="btn sk-btn-orange mb-1" href="{{ pathto('install') }}" role="button">📦 Installation Guide</a>
      </div>
      <div class="col-md-6 d-flex">
        <ul class="sk-landing-header-body">
          <li><strong>⚡ Automatic JAX Acceleration:</strong> 5x+ faster training with zero code changes</li>
          <li><strong>🖥️ Multi-Hardware Support:</strong> CPU, GPU, and TPU acceleration</li>
          <li><strong>🧠 Intelligent Switching:</strong> Automatically chooses optimal hardware</li>
          <li><strong>🔄 100% API Compatible:</strong> Drop-in replacement for scikit-learn</li>
          <li><strong>🔬 Production Ready:</strong> 13,058 tests passed, robust fallback system</li>
          <li><strong>📊 Open Source:</strong> BSD license, built on JAX ecosystem</li>
        </ul>
      </div>
    </div>
  </div>
</div>

{% endblock docs_navbar %}

{% block docs_main %}

<!-- JAX Acceleration Showcase -->
<div class="container-fluid bg-light py-4 mb-4">
  <div class="container sk-landing-container">
    <div class="row text-center">
      <div class="col-12 mb-4">
        <h2 class="sk-landing-call-header">🚀 JAX Acceleration in Action</h2>
        <p class="lead">Experience the power of automatic hardware acceleration</p>
      </div>
    </div>
    <div class="row">
      <div class="col-md-4 mb-3">
        <div class="card h-100 border-success">
          <div class="card-body text-center">
            <h3 class="text-success">⚡ 5.53x</h3>
            <h5 class="card-title">GPU Acceleration</h5>
            <p class="card-text">Linear Regression on 100K×1K dataset</p>
            <small class="text-muted">0.060s vs 0.331s (scikit-learn)</small>
          </div>
        </div>
      </div>
      <div class="col-md-4 mb-3">
        <div class="card h-100 border-info">
          <div class="card-body text-center">
            <h3 class="text-info">🧠 Auto</h3>
            <h5 class="card-title">Smart Selection</h5>
            <p class="card-text">Automatically chooses CPU/GPU/TPU</p>
            <small class="text-muted">Based on data size and algorithm</small>
          </div>
        </div>
      </div>
      <div class="col-md-4 mb-3">
        <div class="card h-100 border-warning">
          <div class="card-body text-center">
            <h3 class="text-warning">🔄 Zero</h3>
            <h5 class="card-title">Code Changes</h5>
            <p class="card-text">Just replace import statement</p>
            <small class="text-muted">import xlearn as sklearn</small>
          </div>
        </div>
      </div>
    </div>
    <div class="row mt-4">
      <div class="col-12 text-center">
        <h4>Quick Example:</h4>
        <pre class="bg-dark text-light p-3 rounded"><code># Before: import sklearn
import xlearn as sklearn  # 🚀 That's it!

# Everything else stays the same
model = sklearn.linear_model.LinearRegression()
model.fit(X, y)  # Automatically uses GPU if beneficial</code></pre>
      </div>
    </div>
  </div>
</div>

<div class="container sk-landing-container pt-3 sk-landing-body" role="main">
  <div class="row no-gutters">
    <!-- Classification -->
    <div class="col-md-4 mb-3 px-md-2 sk-px-xl-4">
      <div class="card h-100" sk-align-group="1">
        <div class="card-body">
          <h4 class="sk-card-title card-title sk-vert-align" sk-align-name="title">
            <a href="supervised_learning.html">Classification</a>
            <span class="badge bg-success ms-2">⚡ JAX</span>
          </h4>
          <p class="sk-vert-align" sk-align-name="desc">Identifying which category an object belongs to with JAX acceleration.</p>
          <p>
            <strong>Applications:</strong> Spam detection, image recognition.</br>
            <strong>JAX-Accelerated:</strong>
            <a href="modules/linear_model.html#logistic-regression">logistic regression</a>,
            <a href="modules/neighbors.html#classification">nearest neighbors</a>.</br>
            <strong>Traditional:</strong>
            <a href="modules/ensemble.html#histogram-based-gradient-boosting">Gradient boosting</a>,
            <a href="modules/ensemble.html#forest">random forest</a>,
            and <a href="supervised_learning.html">more...</a>
          </p>
        </div>
        <div class="sk-card-img-container overflow-hidden mx-2 flex-fill">
          <a href="auto_examples/classification/plot_classifier_comparison.html" aria-label="Classification">
            <img src="_images/sphx_glr_plot_classifier_comparison_001_carousel.png" alt="Classifier comparison">
          </a>
        </div>
        <a href="auto_examples/classification/index.html" class="sk-btn-cyan btn" role="button">Examples</a>
      </div>
    </div>
    <!-- Regression -->
    <div class="col-md-4 mb-3 px-md-2 sk-px-xl-4">
      <div class="card h-100" sk-align-group="1">
        <div class="card-body">
          <h4 class="sk-card-title card-title sk-vert-align" sk-align-name="title">
            <a href="supervised_learning.html">Regression</a>
            <span class="badge bg-success ms-2">⚡ JAX</span>
          </h4>
          <p class="sk-vert-align" sk-align-name="desc">Predicting continuous values with up to 5x faster JAX acceleration.</p>
          <p>
            <strong>Applications:</strong> Drug response, stock prices.</br>
            <strong>JAX-Accelerated:</strong>
            <a href="modules/linear_model.html">LinearRegression</a>,
            <a href="modules/linear_model.html#ridge-regression-and-classification">Ridge</a>,
            <a href="modules/linear_model.html">Lasso</a>.</br>
            <strong>Traditional:</strong>
            <a href="modules/ensemble.html#histogram-based-gradient-boosting">Gradient boosting</a>,
            <a href="modules/ensemble.html#forest">random forest</a>,
            and <a href="supervised_learning.html">more...</a>
          </p>
        </div>
        <div class="sk-card-img-container overflow-hidden mx-2 flex-fill">
          <a href="auto_examples/ensemble/plot_hgbt_regression.html" aria-label="Regression">
            <img src="_images/sphx_glr_plot_hgbt_regression_002.png" alt="Decision Tree Regression with HGBT">
          </a>
        </div>
        <a href="auto_examples/index.html" class="sk-btn-cyan btn" role="button">Examples</a>
      </div>
    </div>
    <!-- Clustering -->
    <div class="col-md-4 mb-3 px-md-2 sk-px-xl-4">
      <div class="card h-100" sk-align-group="1">
        <div class="card-body">
          <h4 class="sk-card-title card-title sk-vert-align" sk-align-name="title">
            <a href="modules/clustering.html">Clustering</a>
            <span class="badge bg-success ms-2">⚡ JAX</span>
          </h4>
          <p class="sk-vert-align" sk-align-name="desc">Automatic grouping with GPU/TPU acceleration for large datasets.</p>
          <p>
            <strong>Applications:</strong> Customer segmentation, grouping experiment outcomes.</br>
            <strong>JAX-Accelerated:</strong>
            <a href="modules/clustering.html#k-means">K-Means</a> (5x+ faster).</br>
            <strong>Traditional:</strong>
            <a href="modules/clustering.html#hdbscan">HDBSCAN</a>,
            <a href="modules/clustering.html#hierarchical-clustering">hierarchical clustering</a>,
            and <a href="modules/clustering.html">more...</a>
          </p>
        </div>
        <div class="sk-card-img-container overflow-hidden mx-2 flex-fill">
          <a href="auto_examples/cluster/plot_kmeans_digits.html" aria-label="Clustering">
            <img src="_images/sphx_glr_plot_kmeans_digits_thumb.png" alt="A demo of K-Means clustering on the handwritten digits data">
          </a>
        </div>
        <a href="auto_examples/cluster/index.html" class="sk-btn-cyan btn" role="button">Examples</a>
      </div>
    </div>
    <!-- Dimensionality reduction -->
    <div class="col-md-4 mb-3 px-md-2 sk-px-xl-4">
      <div class="card h-100" sk-align-group="2">
        <div class="card-body">
          <h4 class="sk-card-title card-title sk-vert-align" sk-align-name="title">
            <a href="modules/decomposition.html">Dimensionality reduction</a>
            <span class="badge bg-success ms-2">⚡ JAX</span>
          </h4>
          <p class="sk-vert-align" sk-align-name="desc">Reducing dimensions with JAX-accelerated linear algebra.</p>
          <p>
            <strong>Applications:</strong> Visualization, increased efficiency.</br>
            <strong>JAX-Accelerated:</strong>
            <a href="modules/decomposition.html#pca">PCA</a>,
            <a href="modules/decomposition.html">TruncatedSVD</a>.</br>
            <strong>Traditional:</strong>
            <a href="modules/feature_selection.html#feature-selection">feature selection</a>,
            <a href="modules/decomposition.html#nmf">NMF</a>,
            and <a href="modules/decomposition.html">more...</a>
          </p>
        </div>
        <div class="sk-card-img-container overflow-hidden mx-2 flex-fill">
          <a href="auto_examples/decomposition/plot_pca_iris.html" aria-label="Dimensionality reduction">
            <img src="_images/sphx_glr_plot_pca_iris_thumb.png" alt="PCA example with Iris Data-set">
          </a>
        </div>
        <a href="auto_examples/decomposition/index.html" class="sk-btn-cyan btn" role="button">Examples</a>
      </div>
    </div>
    <!-- Model selection -->
    <div class="col-md-4 mb-3 px-md-2 sk-px-xl-4">
      <div class="card h-100" sk-align-group="2">
        <div class="card-body">
          <h4 class="sk-card-title card-title sk-vert-align" sk-align-name="title">
            <a href="model_selection.html">Model selection</a>
          </h4>
          <p class="sk-vert-align" sk-align-name="desc">Comparing, validating and choosing parameters and models.</p>
          <p>
            <strong>Applications:</strong> Improved accuracy via parameter tuning.</br>
            <strong>Algorithms:</strong>
            <a href="modules/grid_search.html">Grid search</a>,
            <a href="modules/cross_validation.html">cross validation</a>,
            <a href="modules/model_evaluation.html">metrics</a>,
            and <a href="model_selection.html">more...</a>
          </p>
        </div>
        <div class="sk-card-img-container overflow-hidden mx-2 flex-fill">
          <a href="auto_examples/model_selection/plot_multi_metric_evaluation.html" aria-label="Model selection">
            <img src="_images/sphx_glr_plot_multi_metric_evaluation_thumb.png" alt="Demonstration of multi-metric evaluation on cross_val_score and GridSearchCV">
          </a>
        </div>
        <a href="auto_examples/model_selection/index.html" class="sk-btn-cyan btn" role="button">Examples</a>
      </div>
    </div>
    <!-- Preprocessing -->
    <div class="col-md-4 mb-3 px-md-2 sk-px-xl-4">
      <div class="card h-100" sk-align-group="2">
        <div class="card-body">
          <h4 class="sk-card-title card-title sk-vert-align" sk-align-name="title">
            <a href="modules/preprocessing.html">Preprocessing</a>
            <span class="badge bg-success ms-2">⚡ JAX</span>
          </h4>
          <p class="sk-vert-align" sk-align-name="desc">Feature extraction and normalization with JAX acceleration.</p>
          <p>
            <strong>Applications:</strong> Transforming input data for ML algorithms.</br>
            <strong>JAX-Accelerated:</strong>
            <a href="modules/preprocessing.html">StandardScaler</a>,
            <a href="modules/preprocessing.html">MinMaxScaler</a>.</br>
            <strong>Traditional:</strong>
            <a href="modules/feature_extraction.html">feature extraction</a>,
            and <a href="modules/preprocessing.html">more...</a>
          </p>
        </div>
        <div class="sk-card-img-container overflow-hidden mx-2 flex-fill">
          <a href="auto_examples/preprocessing/plot_discretization_strategies.html" aria-label="Preprocessing">
            <img src="_images/sphx_glr_plot_discretization_strategies_thumb.png" alt="Demonstrating the different strategies of KBinsDiscretizer">
          </a>
        </div>
        <a href="auto_examples/preprocessing/index.html" class="sk-btn-cyan btn" role="button">Examples</a>
      </div>
    </div>
  </div>
</div>

{% endblock docs_main %}

{% block footer %}

<div class="container-fluid sk-landing-more-info py-3">
  <div class="container sk-landing-container bd-page-width">
    <div class="row">
      <!-- News -->
      <div class="col-md-4">
        <h4 class="sk-landing-call-header">🚀 JAX-sklearn News</h4>
        <ul class="sk-landing-call-list list-unstyled">
          <li><strong>🎉 January 2025.</strong> JAX-sklearn v0.1.0 is now live on PyPI! <span class="badge bg-success">Production Ready</span></li>
          <li><strong>✅ Test Success:</strong> 13,058 tests passed (99.99% success rate)</li>
          <li><strong>⚡ Performance:</strong> 5.53x faster training, 5.57x faster batch prediction</li>
          <li><strong>🖥️ Multi-Hardware:</strong> CPU, GPU, and TPU acceleration support</li>
          <li><strong>🔄 Drop-in:</strong> 100% scikit-learn API compatibility</li>
          <li><strong>📦 Easy Install:</strong> <code>pip install jax-sklearn</code></li>
          <li><strong>🧠 Intelligent:</strong> Automatic hardware selection based on data size</li>
          <li><strong>All releases:</strong> <a href="https://github.com/chenxingqiang/jax-sklearn/releases"><strong>GitHub Releases</strong></a>.</li>
        </ul>
      </div>
      <!-- Community -->
      <div class="col-md-4">
        <h4 class="sk-landing-call-header">🤝 JAX-sklearn Community</h4>
        <ul class="sk-landing-call-list list-unstyled">
          <li><strong>🏠 GitHub:</strong> <a href="https://github.com/chenxingqiang/jax-sklearn">Source Code & Issues</a></li>
          <li><strong>💬 Discussions:</strong> <a href="https://github.com/chenxingqiang/jax-sklearn/discussions">GitHub Discussions</a></li>
          <li><strong>📚 Documentation:</strong> <a href="{{ pathto('user_guide') }}">User Guide</a> and <a href="{{ pathto('api/index') }}">API Reference</a></li>
          <li><strong>🐛 Bug Reports:</strong> <a href="https://github.com/chenxingqiang/jax-sklearn/issues">GitHub Issues</a></li>
          <li><strong>🤝 Contributing:</strong> <a href="{{ contributing_link }}" {{ contributing_attrs }}>Contribution Guide</a></li>
          <li><strong>❓ Questions:</strong> <a href="faq.html">FAQ</a> and <a href="support.html">Support</a></li>
          <li><strong>🔗 JAX Ecosystem:</strong> <a href="https://github.com/google/jax">JAX</a>, <a href="https://flax.readthedocs.io/">Flax</a>, <a href="https://optax.readthedocs.io/">Optax</a></li>
          <li><strong>📊 Related:</strong> <a href="related_projects.html">ML Projects</a></li>
          <li><strong>🎨 Branding:</strong> <a href="https://github.com/chenxingqiang/jax-sklearn/tree/main/doc/logos">Logos</a></li>
        </ul>
        <p>
          <a class="btn sk-btn-orange mb-1" href="https://github.com/chenxingqiang/jax-sklearn">⭐ <strong>Star us!</strong></a>
          <a class="btn sk-btn-orange mb-1" href="about.html#citing-jax-sklearn"><strong>📝 Cite us!</strong></a>
        </p>
      </div>
      <!--JAX Ecosystem -->
      <div class="col-md-4">
        <h4 class="sk-landing-call-header">🚀 Why JAX-sklearn?</h4>
        <div class="mb-3">
          <div class="card border-success mb-2">
            <div class="card-body py-2">
              <h6 class="card-title mb-1">⚡ Performance</h6>
              <small class="text-muted">"5.53x faster training with zero code changes"</small>
            </div>
          </div>
          <div class="card border-info mb-2">
            <div class="card-body py-2">
              <h6 class="card-title mb-1">🖥️ Multi-Hardware</h6>
              <small class="text-muted">"Automatic GPU/TPU acceleration when beneficial"</small>
            </div>
          </div>
          <div class="card border-warning mb-2">
            <div class="card-body py-2">
              <h6 class="card-title mb-1">🔄 Drop-in</h6>
              <small class="text-muted">"100% scikit-learn API compatibility"</small>
            </div>
          </div>
          <div class="card border-primary mb-2">
            <div class="card-body py-2">
              <h6 class="card-title mb-1">🧠 Intelligent</h6>
              <small class="text-muted">"Smart hardware selection based on data size"</small>
            </div>
          </div>
          <div class="card border-secondary mb-2">
            <div class="card-body py-2">
              <h6 class="card-title mb-1">🔬 Production</h6>
              <small class="text-muted">"13,058 tests passed, robust fallback system"</small>
            </div>
          </div>
        </div>
        <p class="text-center">
          <a class="btn btn-success btn-sm" href="{{ pathto('getting_started') }}">🚀 Get Started</a>
          <a class="btn btn-outline-primary btn-sm" href="https://github.com/chenxingqiang/jax-sklearn">📖 Learn More</a>
        </p>
      </div>
    </div>
  </div>
</div>

<div class="container-fluid sk-landing-footer py-3">
  <div class="container sk-landing-container">
    <div class="text-center">
      <p class="mt-2 sk-footer-funding-text">
        <strong>JAX-sklearn</strong> is built on the powerful JAX ecosystem and scikit-learn foundation
      </p>
      <div class="sk-footer-funding-logos">
        <div class="d-flex justify-content-center align-items-center flex-wrap">
          <div class="mx-3 mb-2">
            <a href="https://github.com/google/jax" target="_blank" rel="noopener">
              <img src="_static/jax-logo-small.png" title="JAX - Google" alt="JAX" style="height: 40px;">
            </a>
          </div>
          <div class="mx-3 mb-2">
            <a href="https://scikit-learn.org" target="_blank" rel="noopener">
              <img src="_static/scikit-learn-logo-small.png" title="scikit-learn" alt="scikit-learn" style="height: 40px;">
            </a>
          </div>
          <div class="mx-3 mb-2">
            <a href="https://numpy.org" target="_blank" rel="noopener">
              <img src="_static/numpy-small.png" title="NumPy" alt="NumPy" style="height: 40px;">
            </a>
          </div>
          <div class="mx-3 mb-2">
            <a href="https://scipy.org" target="_blank" rel="noopener">
              <img src="_static/scipy-small.png" title="SciPy" alt="SciPy" style="height: 40px;">
            </a>
          </div>
        </div>
      </div>
      <p class="mt-3 text-muted small">
        🚀 <strong>JAX-sklearn</strong>: Accelerating traditional machine learning with modern hardware<br>
        Built with ❤️ by the open source community
      </p>
    </div>
  </div>
</div>

{% endblock footer %}

{%- block scripts_end %}
{{ _webpack.body_post() }}
{%- endblock scripts_end %}
