From 093ed450c6ed4df40676a914805f7f6b4fe3a42c Mon Sep 17 00:00:00 2001 From: Aman Patel Date: Fri, 3 May 2019 01:53:19 +0530 Subject: [PATCH 1/5] Deleted CONTRIBUTING.md --- CONTRIBUTING.md | 113 ------------------------------------------------ 1 file changed, 113 deletions(-) delete mode 100644 CONTRIBUTING.md diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md deleted file mode 100644 index 04535605a5..0000000000 --- a/CONTRIBUTING.md +++ /dev/null @@ -1,113 +0,0 @@ -# Contributing - -Interested in contributing to TensorFlow Addons? We appreciate all kinds -of help and are working to make this guide as comprehensive as possible. -Please [let us know](https://github.com/tensorflow/addons/issues) if -you think of something we could do to help lower the barrier to -contributing. - -## Pull Requests - -We gladly welcome [pull requests]( -https://help.github.com/articles/about-pull-requests/). - -Before making any changes, we recommend opening an issue (if it -doesn't already exist) and discussing your proposed changes. This will -let us give you advice on the proposed changes. If the changes are -minor, then feel free to make them without discussion. - -Want to contribute but not sure of what? Here are a few suggestions: -1. Add a new example or tutorial. Located in [`examples/`](examples), - these are a great way to familiarize yourself and others with TF-Addons. -2. Solve an [existing issue](https://github.com/tensorflow/addons/issues). - These range from low-level software bugs to higher-level design problems. - Check out the label [help wanted](https://github.com/tensorflow/addons/issues?q=is%3Aopen+is%3Aissue+label%3A%22help+wanted%22). If you're a new contributor, the label [good first issue](https://github.com/tensorflow/addons/issues?q=is%3Aissue+is%3Aopen+label%3A%22good+first+issue%22) can be a good place to start. - -All submissions, including submissions by project members, require -review. - -## Requirements for New Contributions to the Repository -The tensorflow/addons repository contains additional functionality -fitting the following criteria: - -* The functionality is not otherwise available in TensorFlow -* Addons have to be compatible with TensorFlow 2.x. -* The addon conforms to the code and documentation standards -* The addon is impactful to the community (e.g. an implementation used - in widely cited paper) - * Lastly, the functionality conforms to the contribution guidelines of - its API pattern: - * [Layers](tensorflow_addons/layers/README.md) | - [Optimizers](tensorflow_addons/optimizers/README.md) | - [Losses](tensorflow_addons/losses/README.md) | - [Custom Ops](tensorflow_addons/custom_ops/README.md) - -**Note: New contributions often require team-members to read a research -paper and understand how it fits into the TensorFlow community. This -process can take longer than typical commit reviews so please bare with -us** - - -## Development Environment -It is recommended that development is done in the latest -`nightly-custom-op` docker image. - -```bash -docker run --rm -it -v ${PWD}:/addons -w /addons tensorflow/tensorflow:nightly-custom-op /bin/bash -``` - -Try those commands below: - -0. Format codes automatically: `make code-format` -1. Sanity check: `make sanity-check` -2. Run unit test: `make unit-test` -3. All of the above: `make` - -## Coding style - -Addons provides `make code-format` command to format your changes -automatically, don't forget to use it before pushing your codes. - -Please see our [Style Guide](STYLE_GUIDE.md) for more details. - -## Code Testing -#### CI Testing -We're in the process of setting up our nightly CI testing. Because this -project will contain CUDA kernels, we need to make sure that the -hardware will be available from our CI provider. - -#### Locally Testing - -```bash -docker run --rm -it -v ${PWD}:/addons -w /addons tensorflow/tensorflow:nightly-custom-op make unit-test -``` - -or run manually: - -```bash -docker run --rm -it -v ${PWD}:/addons -w /addons tensorflow/tensorflow:nightly-custom-op /bin/bash - -./configure.sh # Links project with TensorFlow dependency - -bazel test -c opt -k \ ---test_timeout 300,450,1200,3600 \ ---test_output=errors \ -//tensorflow_addons/... -``` - -## Code Reviews - -All submissions, including submissions by project members, require review. We -use Github pull requests for this purpose. - -## Contributor License Agreement - -Contributions to this project must be accompanied by a Contributor License -Agreement. You (or your employer) retain the copyright to your contribution; -this simply gives us permission to use and redistribute your contributions as -part of the project. Head over to https://cla.developers.google.com/ to see -your current agreements on file or to sign a new one. - -You generally only need to submit a CLA once, so if you've already submitted one -(even if it was for a different project), you probably don't need to do it -again. From a93df7451e74d4295d6d8ca7b662ae04736b13d6 Mon Sep 17 00:00:00 2001 From: Aman Patel Date: Fri, 3 May 2019 01:54:22 +0530 Subject: [PATCH 2/5] Added Contributing.ipynb --- CONTRIBUTING.ipynb | 306 +++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 306 insertions(+) create mode 100644 CONTRIBUTING.ipynb diff --git a/CONTRIBUTING.ipynb b/CONTRIBUTING.ipynb new file mode 100644 index 0000000000..acfb2f98d0 --- /dev/null +++ b/CONTRIBUTING.ipynb @@ -0,0 +1,306 @@ +{ + "cells": [ + { + "cell_type": "markdown", + "metadata": { + "colab_type": "text", + "id": "Tce3stUlHN0L" + }, + "source": [ + "##### Copyright 2018 The TensorFlow Authors.\n", + "\n" + ] + }, + { + "cell_type": "code", + "execution_count": 0, + "metadata": { + "colab": {}, + "colab_type": "code", + "id": "tuOe1ymfHZPu" + }, + "outputs": [], + "source": [ + "#@title Licensed under the Apache License, Version 2.0 (the \"License\");\n", + "# you may not use this file except in compliance with the License.\n", + "# You may obtain a copy of the License at\n", + "#\n", + "# https://www.apache.org/licenses/LICENSE-2.0\n", + "#\n", + "# Unless required by applicable law or agreed to in writing, software\n", + "# distributed under the License is distributed on an \"AS IS\" BASIS,\n", + "# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n", + "# See the License for the specific language governing permissions and\n", + "# limitations under the License." + ] + }, + { + "cell_type": "markdown", + "metadata": { + "colab_type": "text", + "id": "MfBg1C5NB3X0" + }, + "source": [ + "## SIG Addons\n", + "\n", + "# Tensorflow\n", + "\n", + "\n", + " \n", + "
\n", + " View source on GitHub\n", + "
" + ] + }, + { + "cell_type": "markdown", + "metadata": { + "colab_type": "text", + "id": "xHxb-dlhMIzW" + }, + "source": [ + "# Contributing\n", + "\n", + "\n", + "Interested in contributing to TensorFlow Addons? We appreciate all kinds\n", + "of help and are working to make this guide as comprehensive as possible.\n", + "Please [let us know](https://github.com/tensorflow/addons/issues) if\n", + "you think of something we could do to help lower the barrier to\n", + "contributing.\n", + "\n", + "\n" + ] + }, + { + "cell_type": "markdown", + "metadata": { + "colab_type": "text", + "id": "MUXex9ctTuDB" + }, + "source": [ + "### Pull Requests" + ] + }, + { + "cell_type": "markdown", + "metadata": { + "colab": {}, + "colab_type": "code", + "id": "IqR2PQG4ZaZ0" + }, + "source": [ + "We gladly welcome [pull requests](\n", + "https://help.github.com/articles/about-pull-requests/).\n", + "\n", + "Before making any changes, we recommend opening an issue (if it\n", + "doesn't already exist) and discussing your proposed changes. This will\n", + "let us give you advice on the proposed changes. If the changes are\n", + "minor, then feel free to make them without discussion.\n", + "\n", + "Want to contribute but not sure of what? Here are a few suggestions:\n", + "1. Add a new example or tutorial. Located in [`/examples/`](https://github.com/tensorflow/addons/tree/master/examples),\n", + " these are a great way to familiarize yourself and others with TF-Addons.\n", + " \n", + "2. Solve an [existing issue](https://github.com/tensorflow/addons/issues).\n", + " These range from low-level software bugs to higher-level design problems.\n", + " Check out the label [help wanted](https://github.com/tensorflow/addons/issues?q=is%3Aopen+is%3Aissue+label%3A%22help+wanted%22). \n", + " \n", + " If you're a new contributor, the label [good first issue](https://github.com/tensorflow/addons/issues?q=is%3Aissue+is%3Aopen+label%3A%22good+first+issue%22) can be a good place to start.\n", + "\n", + "All submissions, including submissions by project members, require\n", + "review." + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Requirements for New Contributions to the Repository\n", + "\n", + "The tensorflow/addons repository contains additional functionality\n", + "fitting the following criteria:\n", + "\n", + "* The functionality is not otherwise available in TensorFlow\n", + "* Addons have to be compatible with TensorFlow 2.x.\n", + "* The addon conforms to the code and documentation standards\n", + "* The addon is impactful to the community (e.g. an implementation used in widely cited paper)\n", + "* Lastly, the functionality conforms to the contribution guidelines of its API pattern:\n", + " \n", + " * [Layers](https://github.com/tensorflow/addons/blob/master/tensorflow_addons/layers/README.md) |\n", + " [Optimizers](https://github.com/tensorflow/addons/blob/master/tensorflow_addons/optimizers/README.md) |\n", + " [Losses](https://github.com/tensorflow/addons/blob/master/tensorflow_addons/losses/README.md) |\n", + " [Custom Ops](https://github.com/tensorflow/addons/blob/master/tensorflow_addons/custom_ops/README.md)\n", + "\n", + "\n", + "**Note: New contributions often require team-members to read a research\n", + "paper and understand how it fits into the TensorFlow community. This\n", + "process can take longer than typical commit reviews so please bare with\n", + "us**" + ] + }, + { + "cell_type": "markdown", + "metadata": { + "colab_type": "text", + "id": "UhNtHfuxCGVy" + }, + "source": [ + "## Notes" + ] + }, + { + "cell_type": "markdown", + "metadata": { + "colab_type": "text", + "id": "kKhmFeraTdEI" + }, + "source": [ + "Every `example` notebook will have a link to `Colab`, but the link must be written in their correct spot on the master branch once they're merged in.\n", + "\n", + "For example the user should:\n", + "\n", + "`https://colab.research.google.com/github/tensorflow/addons/blob/master/examples/foo.ipynb`\n", + "\n", + "For more help you can check the current examples present in the [`directory`](https://github.com/tensorflow/addons/tree/master/examples)\n", + "\n", + "\n", + "You can also use [ReviewNB](https://www.reviewnb.com), a code review tool for Jupyter Notebooks.It is a visual diff for Notebooks stored on GitHub.\n", + "\n", + "This needs a small installation on your github repository. You can check out [this](https://www.reviewnb.com) link to read about `reviewNB`\n", + "\n" + ] + }, + { + "cell_type": "markdown", + "metadata": { + "colab_type": "text", + "id": "2V22fKegUtF9" + }, + "source": [ + "## Development Environment\n", + "It is recommended that development is done in the latest\n", + "`nightly-custom-op` docker image.\n", + "\n", + "```bash\n", + "docker run --rm -it -v ${PWD}:/addons -w /addons tensorflow/tensorflow:nightly-custom-op /bin/bash\n", + "```\n", + "\n", + "Try those commands below:\n", + "\n", + "0. Format codes automatically: `make code-format`\n", + "1. Sanity check: `make sanity-check`\n", + "2. Run unit test: `make unit-test`\n", + "3. All of the above: `make`" + ] + }, + { + "cell_type": "markdown", + "metadata": { + "colab_type": "text", + "id": "QKp40qS-DGEZ" + }, + "source": [ + "\n", + "## Coding style\n", + "\n", + "Addons provides `make code-format` command to format your changes\n", + "automatically, don't forget to use it before pushing your codes.\n", + "\n", + "Please see our [Style Guide](STYLE_GUIDE.md) for more details.\n", + "\n", + "## Code Testing\n", + "#### CI Testing\n", + "We're in the process of setting up our nightly CI testing. Because this\n", + "project will contain CUDA kernels, we need to make sure that the\n", + "hardware will be available from our CI provider.\n", + "\n", + "#### Locally Testing\n", + "\n", + "```bash\n", + "docker run --rm -it -v ${PWD}:/addons -w /addons tensorflow/tensorflow:nightly-custom-op make unit-test\n", + "```\n", + "\n", + "or run manually:\n", + "\n", + "```bash\n", + "docker run --rm -it -v ${PWD}:/addons -w /addons tensorflow/tensorflow:nightly-custom-op /bin/bash\n", + "\n", + "./configure.sh # Links project with TensorFlow dependency\n", + "\n", + "bazel test -c opt -k \\\n", + "--test_timeout 300,450,1200,3600 \\\n", + "--test_output=errors \\\n", + "//tensorflow_addons/..." + ] + }, + { + "cell_type": "markdown", + "metadata": { + "colab_type": "text", + "id": "g3-lzxbCZi-H" + }, + "source": [ + "## Code Reviews\n", + "\n", + "All submissions, including submissions by project members, require review. We\n", + "use Github pull requests for this purpose.\n", + "\n" + ] + }, + { + "cell_type": "markdown", + "metadata": { + "colab_type": "text", + "id": "TJdqBNBbS78n" + }, + "source": [ + "## Contributor License Agreement\n", + "\n", + "Contributions to this project must be accompanied by a Contributor License\n", + "Agreement. You (or your employer) retain the copyright to your contribution;\n", + "this simply gives us permission to use and redistribute your contributions as\n", + "part of the project. Head over to https://cla.developers.google.com/ to see\n", + "your current agreements on file or to sign a new one.\n", + "\n", + "You generally only need to submit a CLA once, so if you've already submitted one\n", + "(even if it was for a different project), you probably don't need to do it\n", + "again." + ] + } + ], + "metadata": { + "colab": { + "collapsed_sections": [ + "Tce3stUlHN0L" + ], + "last_runtime": { + "build_target": "//learning/brain/python/client:colab_notebook", + "kind": "private" + }, + "name": "notebook.ipynb", + "private_outputs": true, + "provenance": [], + "toc_visible": true, + "version": "0.3.2" + }, + "kernelspec": { + "display_name": "Python 3", + "language": "python", + "name": "python3" + }, + "language_info": { + "codemirror_mode": { + "name": "ipython", + "version": 3 + }, + "file_extension": ".py", + "mimetype": "text/x-python", + "name": "python", + "nbconvert_exporter": "python", + "pygments_lexer": "ipython3", + "version": "3.7.3" + } + }, + "nbformat": 4, + "nbformat_minor": 1 +} From 8f2cbf322f4318758d460b560ee9f5206403fa31 Mon Sep 17 00:00:00 2001 From: Aman Patel Date: Fri, 3 May 2019 01:58:40 +0530 Subject: [PATCH 3/5] Updated some links --- CONTRIBUTING.ipynb | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/CONTRIBUTING.ipynb b/CONTRIBUTING.ipynb index acfb2f98d0..7886648a6b 100644 --- a/CONTRIBUTING.ipynb +++ b/CONTRIBUTING.ipynb @@ -98,7 +98,7 @@ "minor, then feel free to make them without discussion.\n", "\n", "Want to contribute but not sure of what? Here are a few suggestions:\n", - "1. Add a new example or tutorial. Located in [`/examples/`](https://github.com/tensorflow/addons/tree/master/examples),\n", + "1. Add a new example or tutorial. Located in [`examples`](https://github.com/tensorflow/addons/tree/master/examples),\n", " these are a great way to familiarize yourself and others with TF-Addons.\n", " \n", "2. Solve an [existing issue](https://github.com/tensorflow/addons/issues).\n", @@ -206,7 +206,7 @@ "Addons provides `make code-format` command to format your changes\n", "automatically, don't forget to use it before pushing your codes.\n", "\n", - "Please see our [Style Guide](STYLE_GUIDE.md) for more details.\n", + "Please see our [Style Guide](https://github.com/tensorflow/addons/blob/master/STYLE_GUIDE.md) for more details.\n", "\n", "## Code Testing\n", "#### CI Testing\n", From b9fcd036b25badeff429800f802d284a21562213 Mon Sep 17 00:00:00 2001 From: Aman Patel Date: Sat, 4 May 2019 22:28:00 +0530 Subject: [PATCH 4/5] Updated CONTRIBUTING.md --- CONTRIBUTING.md | 140 ++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 140 insertions(+) create mode 100644 CONTRIBUTING.md diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md new file mode 100644 index 0000000000..693fc47228 --- /dev/null +++ b/CONTRIBUTING.md @@ -0,0 +1,140 @@ +# Contributing + +Interested in contributing to TensorFlow Addons? We appreciate all kinds +of help and are working to make this guide as comprehensive as possible. +Please [let us know](https://github.com/tensorflow/addons/issues) if +you think of something we could do to help lower the barrier to +contributing. + +## Pull Requests + +We gladly welcome [pull requests]( +https://help.github.com/articles/about-pull-requests/). + +Before making any changes, we recommend opening an issue (if it +doesn't already exist) and discussing your proposed changes. This will +let us give you advice on the proposed changes. If the changes are +minor, then feel free to make them without discussion. + +Want to contribute but not sure of what? Here are a few suggestions: +1. Add a new example or tutorial. Located in [`examples/`](examples), + these are a great way to familiarize yourself and others with TF-Addons. +2. Solve an [existing issue](https://github.com/tensorflow/addons/issues). + These range from low-level software bugs to higher-level design problems. + Check out the label [help wanted](https://github.com/tensorflow/addons/issues?q=is%3Aopen+is%3Aissue+label%3A%22help+wanted%22). If you're a new contributor, the label [good first issue](https://github.com/tensorflow/addons/issues?q=is%3Aissue+is%3Aopen+label%3A%22good+first+issue%22) can be a good place to start. + +All submissions, including submissions by project members, require +review. + +## Requirements for New Contributions to the Repository +The tensorflow/addons repository contains additional functionality +fitting the following criteria: + +* The functionality is not otherwise available in TensorFlow +* Addons have to be compatible with TensorFlow 2.x. +* The addon conforms to the code and documentation standards +* The addon is impactful to the community (e.g. an implementation used + in widely cited paper) + * Lastly, the functionality conforms to the contribution guidelines of + its API pattern: + * [Layers](tensorflow_addons/layers/README.md) | + [Optimizers](tensorflow_addons/optimizers/README.md) | + [Losses](tensorflow_addons/losses/README.md) | + [Custom Ops](tensorflow_addons/custom_ops/README.md) + +**Note: New contributions often require team-members to read a research +paper and understand how it fits into the TensorFlow community. This +process can take longer than typical commit reviews so please bare with +us** + +## Colab Support + +You can add examples using both Jupyter Notebook and Colab Notebooks. + +Want to add more examples using COLAB? + +Follow this: + +1) Open [Colab](https://colab.research.google.com/) +2) Add a new example in the [addons/examples](https://github.com/tensorflow/addons/tree/master/examples) directory. +Template to write a example can be found [here](https://github.com/tensorflow/docs/blob/master/tools/templates/notebook.ipynb). + +3) Open File->Save a copy in Github. +4) Authorize your Colab with Github. +5) Save it in the desired branch. + +**Note: +Links in colab notebooks have to be written so that they'll be in the right spot in the master branch. + +For example in the PR the user must link to: + +`https://colab.research.google.com/github/tensorflow/addons/blob/master/examples/foo.ipynb` + + + +## Development Environment +It is recommended that development is done in the latest +`nightly-custom-op` docker image. + +```bash +docker run --rm -it -v ${PWD}:/addons -w /addons tensorflow/tensorflow:nightly-custom-op /bin/bash +``` + +Try those commands below: + +0. Format codes automatically: `make code-format` +1. Sanity check: `make sanity-check` +2. Run unit test: `make unit-test` +3. All of the above: `make` + +## Coding style + +Addons provides `make code-format` command to format your changes +automatically, don't forget to use it before pushing your codes. + +Please see our [Style Guide](STYLE_GUIDE.md) for more details. + +## Code Testing +#### CI Testing +We're in the process of setting up our nightly CI testing. Because this +project will contain CUDA kernels, we need to make sure that the +hardware will be available from our CI provider. + +#### Locally Testing + +```bash +docker run --rm -it -v ${PWD}:/addons -w /addons tensorflow/tensorflow:nightly-custom-op make unit-test +``` + +or run manually: + +```bash +docker run --rm -it -v ${PWD}:/addons -w /addons tensorflow/tensorflow:nightly-custom-op /bin/bash + +./configure.sh # Links project with TensorFlow dependency + +bazel test -c opt -k \ +--test_timeout 300,450,1200,3600 \ +--test_output=errors \ +//tensorflow_addons/... +``` + +## Code Reviews + +All submissions, including submissions by project members, require review. We +use Github pull requests for this purpose. + +For Visual Diffs we prefer to using [reviewNB](www.reviewnb.com). It Simplifies your Notebook Workflows. + + +## Contributor License Agreement + +Contributions to this project must be accompanied by a Contributor License +Agreement. You (or your employer) retain the copyright to your contribution; +this simply gives us permission to use and redistribute your contributions as +part of the project. Head over to https://cla.developers.google.com/ to see +your current agreements on file or to sign a new one. + +You generally only need to submit a CLA once, so if you've already submitted one +(even if it was for a different project), you probably don't need to do it +again. From f60ad87995aad08ad5e7cbbc1bfdb5b2bb709179 Mon Sep 17 00:00:00 2001 From: Aman Patel Date: Sat, 4 May 2019 22:28:27 +0530 Subject: [PATCH 5/5] Deleted CONTRIBUTING.ipynb --- CONTRIBUTING.ipynb | 306 --------------------------------------------- 1 file changed, 306 deletions(-) delete mode 100644 CONTRIBUTING.ipynb diff --git a/CONTRIBUTING.ipynb b/CONTRIBUTING.ipynb deleted file mode 100644 index 7886648a6b..0000000000 --- a/CONTRIBUTING.ipynb +++ /dev/null @@ -1,306 +0,0 @@ -{ - "cells": [ - { - "cell_type": "markdown", - "metadata": { - "colab_type": "text", - "id": "Tce3stUlHN0L" - }, - "source": [ - "##### Copyright 2018 The TensorFlow Authors.\n", - "\n" - ] - }, - { - "cell_type": "code", - "execution_count": 0, - "metadata": { - "colab": {}, - "colab_type": "code", - "id": "tuOe1ymfHZPu" - }, - "outputs": [], - "source": [ - "#@title Licensed under the Apache License, Version 2.0 (the \"License\");\n", - "# you may not use this file except in compliance with the License.\n", - "# You may obtain a copy of the License at\n", - "#\n", - "# https://www.apache.org/licenses/LICENSE-2.0\n", - "#\n", - "# Unless required by applicable law or agreed to in writing, software\n", - "# distributed under the License is distributed on an \"AS IS\" BASIS,\n", - "# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n", - "# See the License for the specific language governing permissions and\n", - "# limitations under the License." - ] - }, - { - "cell_type": "markdown", - "metadata": { - "colab_type": "text", - "id": "MfBg1C5NB3X0" - }, - "source": [ - "## SIG Addons\n", - "\n", - "# Tensorflow\n", - "\n", - "\n", - " \n", - "
\n", - " View source on GitHub\n", - "
" - ] - }, - { - "cell_type": "markdown", - "metadata": { - "colab_type": "text", - "id": "xHxb-dlhMIzW" - }, - "source": [ - "# Contributing\n", - "\n", - "\n", - "Interested in contributing to TensorFlow Addons? We appreciate all kinds\n", - "of help and are working to make this guide as comprehensive as possible.\n", - "Please [let us know](https://github.com/tensorflow/addons/issues) if\n", - "you think of something we could do to help lower the barrier to\n", - "contributing.\n", - "\n", - "\n" - ] - }, - { - "cell_type": "markdown", - "metadata": { - "colab_type": "text", - "id": "MUXex9ctTuDB" - }, - "source": [ - "### Pull Requests" - ] - }, - { - "cell_type": "markdown", - "metadata": { - "colab": {}, - "colab_type": "code", - "id": "IqR2PQG4ZaZ0" - }, - "source": [ - "We gladly welcome [pull requests](\n", - "https://help.github.com/articles/about-pull-requests/).\n", - "\n", - "Before making any changes, we recommend opening an issue (if it\n", - "doesn't already exist) and discussing your proposed changes. This will\n", - "let us give you advice on the proposed changes. If the changes are\n", - "minor, then feel free to make them without discussion.\n", - "\n", - "Want to contribute but not sure of what? Here are a few suggestions:\n", - "1. Add a new example or tutorial. Located in [`examples`](https://github.com/tensorflow/addons/tree/master/examples),\n", - " these are a great way to familiarize yourself and others with TF-Addons.\n", - " \n", - "2. Solve an [existing issue](https://github.com/tensorflow/addons/issues).\n", - " These range from low-level software bugs to higher-level design problems.\n", - " Check out the label [help wanted](https://github.com/tensorflow/addons/issues?q=is%3Aopen+is%3Aissue+label%3A%22help+wanted%22). \n", - " \n", - " If you're a new contributor, the label [good first issue](https://github.com/tensorflow/addons/issues?q=is%3Aissue+is%3Aopen+label%3A%22good+first+issue%22) can be a good place to start.\n", - "\n", - "All submissions, including submissions by project members, require\n", - "review." - ] - }, - { - "cell_type": "markdown", - "metadata": {}, - "source": [ - "## Requirements for New Contributions to the Repository\n", - "\n", - "The tensorflow/addons repository contains additional functionality\n", - "fitting the following criteria:\n", - "\n", - "* The functionality is not otherwise available in TensorFlow\n", - "* Addons have to be compatible with TensorFlow 2.x.\n", - "* The addon conforms to the code and documentation standards\n", - "* The addon is impactful to the community (e.g. an implementation used in widely cited paper)\n", - "* Lastly, the functionality conforms to the contribution guidelines of its API pattern:\n", - " \n", - " * [Layers](https://github.com/tensorflow/addons/blob/master/tensorflow_addons/layers/README.md) |\n", - " [Optimizers](https://github.com/tensorflow/addons/blob/master/tensorflow_addons/optimizers/README.md) |\n", - " [Losses](https://github.com/tensorflow/addons/blob/master/tensorflow_addons/losses/README.md) |\n", - " [Custom Ops](https://github.com/tensorflow/addons/blob/master/tensorflow_addons/custom_ops/README.md)\n", - "\n", - "\n", - "**Note: New contributions often require team-members to read a research\n", - "paper and understand how it fits into the TensorFlow community. This\n", - "process can take longer than typical commit reviews so please bare with\n", - "us**" - ] - }, - { - "cell_type": "markdown", - "metadata": { - "colab_type": "text", - "id": "UhNtHfuxCGVy" - }, - "source": [ - "## Notes" - ] - }, - { - "cell_type": "markdown", - "metadata": { - "colab_type": "text", - "id": "kKhmFeraTdEI" - }, - "source": [ - "Every `example` notebook will have a link to `Colab`, but the link must be written in their correct spot on the master branch once they're merged in.\n", - "\n", - "For example the user should:\n", - "\n", - "`https://colab.research.google.com/github/tensorflow/addons/blob/master/examples/foo.ipynb`\n", - "\n", - "For more help you can check the current examples present in the [`directory`](https://github.com/tensorflow/addons/tree/master/examples)\n", - "\n", - "\n", - "You can also use [ReviewNB](https://www.reviewnb.com), a code review tool for Jupyter Notebooks.It is a visual diff for Notebooks stored on GitHub.\n", - "\n", - "This needs a small installation on your github repository. You can check out [this](https://www.reviewnb.com) link to read about `reviewNB`\n", - "\n" - ] - }, - { - "cell_type": "markdown", - "metadata": { - "colab_type": "text", - "id": "2V22fKegUtF9" - }, - "source": [ - "## Development Environment\n", - "It is recommended that development is done in the latest\n", - "`nightly-custom-op` docker image.\n", - "\n", - "```bash\n", - "docker run --rm -it -v ${PWD}:/addons -w /addons tensorflow/tensorflow:nightly-custom-op /bin/bash\n", - "```\n", - "\n", - "Try those commands below:\n", - "\n", - "0. Format codes automatically: `make code-format`\n", - "1. Sanity check: `make sanity-check`\n", - "2. Run unit test: `make unit-test`\n", - "3. All of the above: `make`" - ] - }, - { - "cell_type": "markdown", - "metadata": { - "colab_type": "text", - "id": "QKp40qS-DGEZ" - }, - "source": [ - "\n", - "## Coding style\n", - "\n", - "Addons provides `make code-format` command to format your changes\n", - "automatically, don't forget to use it before pushing your codes.\n", - "\n", - "Please see our [Style Guide](https://github.com/tensorflow/addons/blob/master/STYLE_GUIDE.md) for more details.\n", - "\n", - "## Code Testing\n", - "#### CI Testing\n", - "We're in the process of setting up our nightly CI testing. Because this\n", - "project will contain CUDA kernels, we need to make sure that the\n", - "hardware will be available from our CI provider.\n", - "\n", - "#### Locally Testing\n", - "\n", - "```bash\n", - "docker run --rm -it -v ${PWD}:/addons -w /addons tensorflow/tensorflow:nightly-custom-op make unit-test\n", - "```\n", - "\n", - "or run manually:\n", - "\n", - "```bash\n", - "docker run --rm -it -v ${PWD}:/addons -w /addons tensorflow/tensorflow:nightly-custom-op /bin/bash\n", - "\n", - "./configure.sh # Links project with TensorFlow dependency\n", - "\n", - "bazel test -c opt -k \\\n", - "--test_timeout 300,450,1200,3600 \\\n", - "--test_output=errors \\\n", - "//tensorflow_addons/..." - ] - }, - { - "cell_type": "markdown", - "metadata": { - "colab_type": "text", - "id": "g3-lzxbCZi-H" - }, - "source": [ - "## Code Reviews\n", - "\n", - "All submissions, including submissions by project members, require review. We\n", - "use Github pull requests for this purpose.\n", - "\n" - ] - }, - { - "cell_type": "markdown", - "metadata": { - "colab_type": "text", - "id": "TJdqBNBbS78n" - }, - "source": [ - "## Contributor License Agreement\n", - "\n", - "Contributions to this project must be accompanied by a Contributor License\n", - "Agreement. You (or your employer) retain the copyright to your contribution;\n", - "this simply gives us permission to use and redistribute your contributions as\n", - "part of the project. Head over to https://cla.developers.google.com/ to see\n", - "your current agreements on file or to sign a new one.\n", - "\n", - "You generally only need to submit a CLA once, so if you've already submitted one\n", - "(even if it was for a different project), you probably don't need to do it\n", - "again." - ] - } - ], - "metadata": { - "colab": { - "collapsed_sections": [ - "Tce3stUlHN0L" - ], - "last_runtime": { - "build_target": "//learning/brain/python/client:colab_notebook", - "kind": "private" - }, - "name": "notebook.ipynb", - "private_outputs": true, - "provenance": [], - "toc_visible": true, - "version": "0.3.2" - }, - "kernelspec": { - "display_name": "Python 3", - "language": "python", - "name": "python3" - }, - "language_info": { - "codemirror_mode": { - "name": "ipython", - "version": 3 - }, - "file_extension": ".py", - "mimetype": "text/x-python", - "name": "python", - "nbconvert_exporter": "python", - "pygments_lexer": "ipython3", - "version": "3.7.3" - } - }, - "nbformat": 4, - "nbformat_minor": 1 -}