<commit_before>Array Operations
================

.. module:: chainerx

Array creation routines
-----------------------

Ones and zeros
^^^^^^^^^^^^^^

.. autosummary::
   :toctree: generated/
   :nosignatures:

   chainerx.empty
   chainerx.empty_like
   chainerx.eye
   chainerx.identity
   chainerx.ones
   chainerx.ones_like
   chainerx.zeros
   chainerx.zeros_like
   chainerx.full
   chainerx.full_like

From existing data
^^^^^^^^^^^^^^^^^^

.. autosummary::
   :toctree: generated/
   :nosignatures:

   chainerx.array
   chainerx.asarray
   chainerx.asanyarray
   chainerx.ascontiguousarray
   chainerx.copy
   chainerx.frombuffer
   chainerx.fromfile
   chainerx.fromfunction
   chainerx.fromiter
   chainerx.fromstring
   chainerx.loadtxt

Numerical ranges
^^^^^^^^^^^^^^^^

.. autosummary::
   :toctree: generated/
   :nosignatures:

   chainerx.arange
   chainerx.linspace

Building matrices
^^^^^^^^^^^^^^^^^

.. autosummary::
   :toctree: generated/
   :nosignatures:

   chainerx.diag
   chainerx.diagflat

Array manipulation routines
---------------------------

.. autosummary::
   :toctree: generated/
   :nosignatures:

   chainerx.reshape
   chainerx.transpose
   chainerx.broadcast_to
   chainerx.squeeze
   chainerx.asarray
   chainerx.ascontiguousarray
   chainerx.asscalar
   chainerx.concatenate
   chainerx.stack
   chainerx.split

Indexing routines
-----------------

.. autosummary::
   :toctree: generated/
   :nosignatures:

   chainerx.take

Linear algebra
--------------

Matrix and vector products
^^^^^^^^^^^^^^^^^^^^^^^^^^

.. autosummary::
   :toctree: generated/
   :nosignatures:

   chainerx.dot

Logic functions
---------------

Logic operations
^^^^^^^^^^^^^^^^

.. autosummary::
   :toctree: generated/
   :nosignatures:

   chainerx.logical_not

Comparison operations
^^^^^^^^^^^^^^^^^^^^^

.. autosummary::
   :toctree: generated/
   :nosignatures:

   chainerx.greater
   chainerx.greater_equal
   chainerx.less
   chainerx.less_equal
   chainerx.equal
   chainerx.not_equal

Mathematical functions
----------------------

.. autosummary::
   :toctree: generated/
   :nosignatures:

   chainerx.negative
   chainerx.add
   chainerx.subtract
   chainerx.multiply
   chainerx.divide
   chainerx.sum
   chainerx.maximum
   chainerx.exp
   chainerx.log
   chainerx.logsumexp
   chainerx.log_softmax
   chainerx.sqrt
   chainerx.tanh
   chainerx.isnan
   chainerx.isinf<commit_msg>Add chainerx.square, and chainerx.random<commit_after>Array Operations
================

.. module:: chainerx

Array creation routines
-----------------------

Ones and zeros
^^^^^^^^^^^^^^

.. autosummary::
   :toctree: generated/
   :nosignatures:

   chainerx.empty
   chainerx.empty_like
   chainerx.eye
   chainerx.identity
   chainerx.ones
   chainerx.ones_like
   chainerx.zeros
   chainerx.zeros_like
   chainerx.full
   chainerx.full_like

From existing data
^^^^^^^^^^^^^^^^^^

.. autosummary::
   :toctree: generated/
   :nosignatures:

   chainerx.array
   chainerx.asarray
   chainerx.asanyarray
   chainerx.ascontiguousarray
   chainerx.copy
   chainerx.frombuffer
   chainerx.fromfile
   chainerx.fromfunction
   chainerx.fromiter
   chainerx.fromstring
   chainerx.loadtxt

Numerical ranges
^^^^^^^^^^^^^^^^

.. autosummary::
   :toctree: generated/
   :nosignatures:

   chainerx.arange
   chainerx.linspace

Building matrices
^^^^^^^^^^^^^^^^^

.. autosummary::
   :toctree: generated/
   :nosignatures:

   chainerx.diag
   chainerx.diagflat

Array manipulation routines
---------------------------

.. autosummary::
   :toctree: generated/
   :nosignatures:

   chainerx.reshape
   chainerx.transpose
   chainerx.broadcast_to
   chainerx.squeeze
   chainerx.asarray
   chainerx.ascontiguousarray
   chainerx.asscalar
   chainerx.concatenate
   chainerx.stack
   chainerx.split

Indexing routines
-----------------

.. autosummary::
   :toctree: generated/
   :nosignatures:

   chainerx.take

Linear algebra
--------------

Matrix and vector products
^^^^^^^^^^^^^^^^^^^^^^^^^^

.. autosummary::
   :toctree: generated/
   :nosignatures:

   chainerx.dot

Logic functions
---------------

Logic operations
^^^^^^^^^^^^^^^^

.. autosummary::
   :toctree: generated/
   :nosignatures:

   chainerx.logical_not

Comparison operations
^^^^^^^^^^^^^^^^^^^^^

.. autosummary::
   :toctree: generated/
   :nosignatures:

   chainerx.greater
   chainerx.greater_equal
   chainerx.less
   chainerx.less_equal
   chainerx.equal
   chainerx.not_equal

Mathematical functions
----------------------

.. autosummary::
   :toctree: generated/
   :nosignatures:

   chainerx.negative
   chainerx.add
   chainerx.subtract
   chainerx.multiply
   chainerx.divide
   chainerx.sum
   chainerx.maximum
   chainerx.exp
   chainerx.log
   chainerx.logsumexp
   chainerx.log_softmax
   chainerx.sqrt
   chainerx.tanh
   chainerx.isnan
   chainerx.isinf
   chainerx.square

Random sampling
---------------

.. autosummary::
   :toctree: generated/
   :nosignatures:

   chainerx.random.normal
   chainerx.random.uniform
{'fraction_non_alphanumeric': 0.17232479650585666, 'fraction_numerical': 0.0, 'mean_word_length': 2.7709580838323356, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '3943452', 'n_tokens_mistral': 1819, 'n_tokens_neox': 1779, 'n_words': 281}