Skip to content
This repository has been archived by the owner on Nov 17, 2023. It is now read-only.

[v1.x] Fix python doc version dropdown #20189

Merged
merged 2 commits into from
Apr 20, 2021
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
19 changes: 10 additions & 9 deletions docs/python_docs/themes/mx-theme/mxtheme/header_top.html
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<header class="site-header" role="banner">
<div class="wrapper">
<a class="site-title" rel="author" href="{{theme_relative_url}}"><img
<a class="site-title" rel="author" href="/versions/1.8.0/"><img
src="{{pathto('_static/mxnet_logo.png', 1)}}" class="site-header-logo"></a>
<nav class="site-nav">
<input type="checkbox" id="nav-trigger" class="nav-trigger"/>
Expand All @@ -13,20 +13,21 @@
</label>

<div class="trigger">
<a class="page-link" href="{{theme_relative_url}}get_started">Get Started</a>
<a class="page-link" href="{{theme_relative_url}}blog">Blog</a>
<a class="page-link" href="{{theme_relative_url}}features">Features</a>
<a class="page-link" href="{{theme_relative_url}}ecosystem">Ecosystem</a>
<a class="page-link page-current" href="{{theme_relative_url}}api">Docs & Tutorials</a>
<a class="page-link" href="/versions/1.8.0/get_started">Get Started</a>
<a class="page-link" href="/versions/1.8.0/blog">Blog</a>
<a class="page-link" href="/versions/1.8.0/features">Features</a>
<a class="page-link" href="/versions/1.8.0/ecosystem">Ecosystem</a>
<a class="page-link page-current" href="/versions/1.8.0/api">Docs & Tutorials</a>
<a class="page-link" href="/~https://github.com/apache/incubator-mxnet">GitHub</a>
<div class="dropdown">
<span class="dropdown-header">1.7
<span class="dropdown-header">1.8.0
<svg class="dropdown-caret" viewBox="0 0 32 32" class="icon icon-caret-bottom" aria-hidden="true"><path class="dropdown-caret-path" d="M24 11.305l-7.997 11.39L8 11.305z"></path></svg>
</span>
<div class="dropdown-content">
<a class="dropdown-option" href="/">master</a><br>
<a class="dropdown-option-active" href="/versions/1.7/">1.7</a><br>
<a class="dropdown-option" href="/versions/1.6/">1.6</a><br>
<a class="dropdown-option-active" href="/versions/1.8.0/">1.8.0</a><br>
<a class="dropdown-option" href="/versions/1.7.0/">1.7.0</a><br>
<a class="dropdown-option" href="/versions/1.6.0/">1.6.0</a><br>
<a class="dropdown-option" href="/versions/1.5.0/">1.5.0</a><br>
<a class="dropdown-option" href="/versions/1.4.1/">1.4.1</a><br>
<a class="dropdown-option" href="/versions/1.3.1/">1.3.1</a><br>
Expand Down
11 changes: 6 additions & 5 deletions tests/python/unittest/test_operator.py
Original file line number Diff line number Diff line change
Expand Up @@ -10041,10 +10041,7 @@ def test_scalarop_locale_invariance():
finally:
locale.setlocale(locale.LC_NUMERIC, prev)

if __name__ == '__main__':
import nose
nose.runmodule()

@with_seed()
def test_take_grads():
# Test for /~https://github.com/apache/incubator-mxnet/issues/19817
from mxnet.gluon.nn import HybridBlock, Conv1D, HybridSequential, HybridLambda, Dense
Expand Down Expand Up @@ -10133,4 +10130,8 @@ def hybrid_forward(self, F, X, axis=-1):
grads2 = run_model(model2, loss, X, Y)

for i in range(len(grads1)):
assert_almost_equal(grads1[i], grads2[i])
assert_almost_equal(grads1[i], grads2[i])
waytrue17 marked this conversation as resolved.
Show resolved Hide resolved

if __name__ == '__main__':
import nose
nose.runmodule()