Skip to content

Commit

Permalink
update version for numpy, sklearn, matplotlib and sympy
Browse files Browse the repository at this point in the history
Several minor fixes for the return values (with ELLIPSIS and
NORMALIZE_WHITESPACE as much as possible)
  • Loading branch information
pdebuyl committed May 23, 2019
1 parent f5b185d commit d234c72
Show file tree
Hide file tree
Showing 9 changed files with 22 additions and 22 deletions.
4 changes: 2 additions & 2 deletions advanced/advanced_numpy/index.rst
Original file line number Diff line number Diff line change
Expand Up @@ -1332,10 +1332,10 @@ Array siblings: :class:`chararray`, :class:`maskedarray`, :class:`matrix`
--------------------------------------------------

>>> x = np.array(['a', ' bbb', ' ccc']).view(np.chararray)
>>> x.lstrip(' ') # doctest: +ELLIPSIS
>>> x.lstrip(' ') # doctest: +ELLIPSIS +NORMALIZE_WHITESPACE
chararray(['a', 'bbb', 'ccc'],
dtype='...')
>>> x.upper() # doctest: +ELLIPSIS
>>> x.upper() # doctest: +ELLIPSIS +NORMALIZE_WHITESPACE
chararray(['A', ' BBB', ' CCC'],
dtype='...')

Expand Down
4 changes: 2 additions & 2 deletions advanced/scipy_sparse/introduction.rst
Original file line number Diff line number Diff line change
Expand Up @@ -32,9 +32,9 @@ Why Sparse Matrices?
>>> plt.plot(x, 8.0 * (x**2) / 1e6, lw=5) # doctest: +ELLIPSIS
[<matplotlib.lines.Line2D object at ...>]
>>> plt.xlabel('size n') # doctest: +ELLIPSIS
<matplotlib.text.Text object at ...>
Text(...,'size n')
>>> plt.ylabel('memory [MB]') # doctest: +ELLIPSIS
<matplotlib.text.Text object at ...>
Text(...,'memory [MB]')

Sparse Matrices vs. Sparse Matrix Storage Schemes
-------------------------------------------------
Expand Down
8 changes: 4 additions & 4 deletions environment.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,12 +3,12 @@
# `./build_tools/requirements_to_environment.py`
name: testenv
dependencies:
- numpy=1.11
- numpy=1.14
- scipy=0.19
- scikit-learn=0.18
- matplotlib=1.5
- scikit-learn=0.19
- matplotlib=2.2
- scikit-image=0.13
- sympy=1.0
- sympy=1.3
- statsmodels=0.8
- seaborn=0.7
- pandas=0.20
Expand Down
6 changes: 3 additions & 3 deletions intro/numpy/elaborate_arrays.rst
Original file line number Diff line number Diff line change
Expand Up @@ -193,9 +193,9 @@ Field access works by indexing with field names::

Multiple fields at once::

>>> samples[['position', 'value']]
array([(1.0, 0.37), (1.0, 0.11), (1.0, 0.13), (1.5, 0.37), (3.0, 0.11),
(1.2, 0.13)],
>>> samples[['position', 'value']] # doctest: +NORMALIZE_WHITESPACE
array([( 1. , 0.37), ( 1. , 0.11), ( 1. , 0.13), ( 1.5, 0.37),
( 3. , 0.11), ( 1.2, 0.13)],
dtype=[('position', '<f8'), ('value', '<f8')])

Fancy indexing works, as usual::
Expand Down
6 changes: 3 additions & 3 deletions intro/numpy/operations.rst
Original file line number Diff line number Diff line change
Expand Up @@ -429,13 +429,13 @@ Other reductions
.. sourcecode:: pycon

>>> plt.figure(figsize=(4, 3)) # doctest: +ELLIPSIS
<matplotlib.figure.Figure object at ...>
<Figure size ... with 0 Axes>
>>> plt.plot(t, np.sqrt(mean_sq_distance), 'g.', t, np.sqrt(t), 'y-') # doctest: +ELLIPSIS
[<matplotlib.lines.Line2D object at ...>, <matplotlib.lines.Line2D object at ...>]
>>> plt.xlabel(r"$t$") # doctest: +ELLIPSIS
<matplotlib.text.Text object at ...>
Text(...,'$t$')
>>> plt.ylabel(r"$\sqrt{\langle (\delta x)^2 \rangle}$") # doctest: +ELLIPSIS
<matplotlib.text.Text object at ...>
Text(...,'$\\sqrt{\\langle (\\delta x)^2 \\rangle}$')
>>> plt.tight_layout() # provide sufficient space for labels

.. image:: auto_examples/images/sphx_glr_plot_randomwalk_001.png
Expand Down
4 changes: 2 additions & 2 deletions packages/scikit-image/index.rst
Original file line number Diff line number Diff line change
Expand Up @@ -638,14 +638,14 @@ Some image processing operations::
Visualize binary result::

>>> plt.figure() # doctest: +ELLIPSIS
<matplotlib.figure.Figure object at 0x...>
<Figure size ... with 0 Axes>
>>> plt.imshow(clean_border, cmap='gray') # doctest: +ELLIPSIS
<matplotlib.image.AxesImage object at 0x...>

Visualize contour ::

>>> plt.figure() # doctest: +ELLIPSIS
<matplotlib.figure.Figure object at 0x...>
<Figure size ... with 0 Axes>
>>> plt.imshow(coins, cmap='gray') # doctest: +ELLIPSIS
<matplotlib.image.AxesImage object at 0x...>
>>> plt.contour(clean_border, [0.5]) # doctest: +ELLIPSIS
Expand Down
2 changes: 1 addition & 1 deletion packages/scikit-learn/index.rst
Original file line number Diff line number Diff line change
Expand Up @@ -747,7 +747,7 @@ others for our problem::
>>> for index, feature_name in enumerate(data.feature_names):
... plt.figure()
... plt.scatter(data.data[:, index], data.target) # doctest: +ELLIPSIS
<matplotlib.figure.Figure object...
<Figure size...

.. image:: auto_examples/images/sphx_glr_plot_boston_prediction_002.png
:width: 32%
Expand Down
2 changes: 1 addition & 1 deletion packages/sympy.rst
Original file line number Diff line number Diff line change
Expand Up @@ -321,7 +321,7 @@ supposed to be equaled to 0. It also has (limited) support for transcendental
equations::

>>> sym.solveset(sym.exp(x) + 1, x)
{I*(2*n*pi + pi) | n in Integers()}
{I*(2*n*pi + pi) | n in Integers}

.. topic:: **Systems of linear equations**

Expand Down
8 changes: 4 additions & 4 deletions requirements.txt
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
# This file is structured in a specific way please include all conda installable
# libraries before the special comment marked `# For conda, pip installable:`
numpy==1.11
numpy==1.14
scipy==0.19
scikit-learn==0.18
matplotlib==1.5
scikit-learn==0.19
matplotlib==2.2
scikit-image==0.13
sympy==1.0
sympy==1.3
statsmodels==0.8
seaborn==0.7
pandas==0.20
Expand Down

0 comments on commit d234c72

Please sign in to comment.