From 1a8c233811bb5ceef9ec37a35d2b502f09a8c8ac Mon Sep 17 00:00:00 2001 From: belsten Date: Sat, 23 Nov 2024 08:45:54 -0800 Subject: [PATCH] fixed typos and minor reword --- docs/contributing.rst | 42 ++++++++++++++++++++----------------- docs/install.rst | 21 +++++++------------ docs/quickstart.rst | 48 ++++++++++++++++++------------------------- 3 files changed, 50 insertions(+), 61 deletions(-) diff --git a/docs/contributing.rst b/docs/contributing.rst index 513741b..16b2981 100644 --- a/docs/contributing.rst +++ b/docs/contributing.rst @@ -2,36 +2,40 @@ Contributing ============ -All contributions are welcome! +We welcome all contributions! Bug Reporting ------------- -If you find a bug, submit a bug report on GitHub Issues. +If you encounter a bug, please report it by creating an issue on GitHub. -Adding Features/Fixing Bugs ---------------------------- +Adding Features or Fixing Bugs +------------------------------ -If you have identified a new feature or bug that you can fix yourself, please follow the following procedure. +If you’ve identified a new feature to add or a bug you can fix, follow these steps: -#. Clone ``main`` branch. -#. Create a new branch to contain your changes. -#. ``add``, ``commit``, and ``push`` your changes to this branch. -#. Create a pull request (PR). See more information on submitting a PR request below. +#. Clone the ``main`` branch. +#. Create a new branch to work on your changes. +#. Use ``add``, ``commit``, and ``push`` to save your changes to the new branch. +#. Create a pull request (PR). See the "Submitting a Pull Request" section for more details. Submitting a Pull Request ------------------------- -#. If necessary, please **write your own unit tests** and add them to `the tests directory `_. -#. Verify that all tests are passed by running `python -m unittest discover tests -vvv`. -#. Be sure that your PR follows formatting guidelines, `PEP8 `_ and `flake8 `_. -#. Make sure the title of your PR summarizes the features/issues resolved in your branch. -#. Submit your pull request and add reviewers. +#. If applicable, write unit tests for your changes and add them to the + `tests directory `_. +#. Verify that all tests pass by running ``python -m unittest discover tests -vvv``. +#. Ensure your code adheres to the formatting guidelines specified in + `PEP8 `_ and validated by + `flake8 `_. +#. Provide a concise and descriptive title for your PR that summarizes the changes made in your branch. +#. Submit your PR and assign reviewers as necessary. Coding Style Guidelines ------------------------ -We adhere to the `NumPy documentation standards `_. +------------------------ -#. Format code in accordance with `flake8 `_ standard. -#. Use underscores to separate words in non-class names: ``n_samples`` rather than ``nsamples``. -#. Avoid single-character variable names. \ No newline at end of file +We follow the `NumPy documentation standards `_. + +1. Format your code according to the `flake8 `_ standard. +2. Use underscores to separate words in non-class names (e.g., ``n_samples`` instead of ``nsamples``). +3. Avoid single-character variable names. diff --git a/docs/install.rst b/docs/install.rst index deff6eb..e71e79f 100644 --- a/docs/install.rst +++ b/docs/install.rst @@ -2,26 +2,19 @@ Installation ============ -The fastest way to install is by cloning the library from Github: +The quickest way to install the library is by cloning it directly from GitHub: .. code:: bash - $ git clone https://github.com/rctn/sparsecoding.git - $ cd sparsecoding - $ pip install -e sparsecoding - $ pip install -r requirements.txt + git clone https://github.com/rctn/sparsecoding.git + cd sparsecoding + pip install -e sparsecoding + pip install -r requirements.txt +The last command installs the dependencies required for the RCTN sparse coding library, including: -The last line of the code above will install the RCTN sparse coding dependencies: - -- ``numpy`` - +- ``numpy`` - ``scipy`` - - ``matplotlib`` - - ``torch`` - - ``torchvision`` - - diff --git a/docs/quickstart.rst b/docs/quickstart.rst index 57e170d..bc6ccb1 100644 --- a/docs/quickstart.rst +++ b/docs/quickstart.rst @@ -7,42 +7,34 @@ Overview .. _sparsecoding: https://github.com/rctn/sparsecoding/ -`sparsecoding`_ is a python package that provides tools for using sparse coding algorithms. -Historically, sparse coding has been largely focused on learning sparse representations -of images and we provide visualization and transformation tools to work with such data. -However, we've tried to structure the dictionary learning methods and inference methods -in a manner that is data-agnostic. +`sparsecoding`_ is a Python package that provides tools for implementing sparse coding algorithms. +Traditionally, sparse coding has been primarily used for learning sparse representations of images. +To support this, we include tools for visualization and data transformation specific to image data. +However, we have designed the dictionary learning and inference methods to be data-agnostic, +allowing for broader applications. -The `sparsecoding`_ library is largely built using PyTorch which enables it to inheret -many performance benifits. These include: +The `sparsecoding`_ library is built largely on PyTorch, enabling it to inherit several +performance benefits, such as: - GPU support - - Batched operations - - Auto-grad optimizers +Structure of the Library +------------------------- +The functionalities of `sparsecoding`_ are organized into several modules: -Structure of library --------------------- - -The functionalities of `sparsecoding`_ are broken into differnent modules. - -- ``sparsecoding.models`` contains dictionary learning models (e.g. SparseCoding). - -- ``sparsecoding.inference`` contains algorithms for computing latent coefficients. - -- ``sparsecoding.visualization`` contains tools for visualizing image dictionaries and data. - -- ``sparsecoding.priors`` contains methods for sampling from various sparse coding priors. - -- ``sparsecoding.datasets`` contains methods for loading datasets. - -- ``sparsecoding.transforms`` contains methods working with data, such as whitening and extracting patches from images. - +- ``sparsecoding.models``: Contains dictionary learning models (e.g., SparseCoding). +- ``sparsecoding.inference``: Includes algorithms for computing latent coefficients. +- ``sparsecoding.visualization``: Provides tools for visualizing image dictionaries and data. +- ``sparsecoding.priors``: Offers methods for sampling from various sparse coding priors. +- ``sparsecoding.datasets``: Contains utilities for loading datasets. +- ``sparsecoding.transforms``: Includes methods for working with data, such as whitening and + extracting patches from images. -Getting started +Getting Started --------------- -`See example notebooks `_. \ No newline at end of file +Explore our `example notebooks `_ +to get started.