Skip to content

Commit 6add81a

Browse files
tensorflower-gardenersampathweb
authored andcommitted
No public description
PiperOrigin-RevId: 563905885
1 parent 94a1712 commit 6add81a

File tree

2,391 files changed

+134710
-134547
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

2,391 files changed

+134710
-134547
lines changed

.github/ISSUE_TEMPLATE/00-bug-template.md

+3-3
Original file line numberDiff line numberDiff line change
@@ -37,17 +37,17 @@ python -c "import tensorflow as tf; print(tf.version.GIT_VERSION, tf.version.VER
3737

3838
**Describe the problem**.
3939

40-
Describe the problem clearly here. Be sure to convey here why it's a bug in Keras or why the requested feature is needed.
40+
Describe the problem clearly here. Be sure to convey here why it's a bug in TF-Keras or why the requested feature is needed.
4141

4242
**Describe the current behavior**.
4343

4444

4545
**Describe the expected behavior**.
4646

47-
**[Contributing](https://github.com/keras-team/keras/blob/master/CONTRIBUTING.md)**.
47+
**[Contributing](https://github.com/keras-team/tf-keras/blob/master/CONTRIBUTING.md)**.
4848

4949
- Do you want to contribute a PR? (yes/no):
50-
- If yes, please read [this page](https://github.com/keras-team/keras/blob/master/CONTRIBUTING.md) for instructions
50+
- If yes, please read [this page](https://github.com/keras-team/tf-keras/blob/master/CONTRIBUTING.md) for instructions
5151
- Briefly describe your candidate solution(if contributing):
5252

5353
**Standalone code to reproduce the issue**.

.github/ISSUE_TEMPLATE/10-feature-request.md

+2-2
Original file line numberDiff line numberDiff line change
@@ -30,8 +30,8 @@ Describe the feature clearly here. Be sure to convey here why the requested feat
3030
**Who will benefit from this feature?**
3131

3232

33-
**[Contributing](https://github.com/keras-team/keras/blob/master/CONTRIBUTING.md)**
33+
**[Contributing](https://github.com/keras-team/tf-keras/blob/master/CONTRIBUTING.md)**
3434

3535
- Do you want to contribute a PR? (yes/no):
36-
- If yes, please read [this page](https://github.com/keras-team/keras/blob/master/CONTRIBUTING.md) for instructions
36+
- If yes, please read [this page](https://github.com/keras-team/tf-keras/blob/master/CONTRIBUTING.md) for instructions
3737
- Briefly describe your candidate solution(if contributing):

.github/ISSUE_TEMPLATE/20-documentation-issue.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -58,6 +58,6 @@ Are there currently visuals? If not, will it clarify the content?
5858

5959
**Submit a pull request?**.
6060

61-
Are you planning to also submit a pull request to fix the issue? See the [docs contributor guide](https://github.com/keras-team/keras/blob/master/CONTRIBUTING.md):
61+
Are you planning to also submit a pull request to fix the issue? See the [docs contributor guide](https://github.com/keras-team/tf-keras/blob/master/CONTRIBUTING.md):
6262

6363

.github/workflows/format.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,7 @@ jobs:
4646
This is a pull request automatically created by a Github Action to format the code.
4747
4848
If there is any conflict, click the run workflow button on
49-
[this page](https://github.com/keras-team/keras/actions/workflows/format.yml).
49+
[this page](https://github.com/keras-team/tf-keras/actions/workflows/format.yml).
5050
labels: |
5151
ready to pull
5252
draft: false

CONTRIBUTING.md

+21-21
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,7 @@ pull request. A team member will take care of the merging.
5656

5757
![Ready to pull](https://i.imgur.com/yCEqJsA.png)
5858

59-
Here is an [example pull request](https://github.com/keras-team/keras/pull/15015)
59+
Here is an [example pull request](https://github.com/keras-team/tf-keras/pull/15015)
6060
for your reference.
6161

6262
## Setup environment
@@ -68,7 +68,7 @@ to setup a local environment by installing the dev tools needed.
6868
### Option 1: Use a Docker container
6969

7070
We provide a
71-
[Dockerfile](https://github.com/keras-team/keras/blob/master/.devcontainer/Dockerfile)
71+
[Dockerfile](https://github.com/keras-team/tf-keras/blob/master/.devcontainer/Dockerfile)
7272
to build the dev environment. You can build the Dockerfile into a Docker image
7373
named `keras-dev` with the following command at the root directory of your
7474
cloned repo.
@@ -79,18 +79,18 @@ docker build -t keras-dev .devcontainer
7979

8080
You can launch a Docker container from the image with the following command. The
8181
`-it` option gives you an interactive shell of the container. The `-v
82-
path/to/repo/:/home/keras/` mounts your cloned repo to the container. Replace
82+
path/to/repo/:/home/tf_keras/` mounts your cloned repo to the container. Replace
8383
`path/to/repo` with the path to your cloned repo directory.
8484

8585
```shell
86-
docker run -it -v path/to/repo/:/home/keras/ keras-dev
86+
docker run -it -v path/to/repo/:/home/tf_keras/ keras-dev
8787
```
8888

8989
In the container shell, you need to install the latest dependencies with the
9090
following command.
9191

9292
```shell
93-
pip install -r /home/keras/requirements.txt && pip uninstall keras-nightly -y
93+
pip install -r /home/tf_keras/requirements.txt && pip uninstall keras-nightly -y
9494
```
9595

9696
Now, the environment setup is complete. You are ready to run the tests.
@@ -107,14 +107,14 @@ with setup instructions.
107107

108108
To setup your local dev environment, you will need the following tools.
109109

110-
1. [Bazel](https://bazel.build/) is the tool to build and test Keras. See the
110+
1. [Bazel](https://bazel.build/) is the tool to build and test TF-Keras. See the
111111
[installation guide](https://docs.bazel.build/versions/4.0.0/install.html)
112112
for how to install and config bazel for your local environment.
113113
2. [git](https://github.com/) for code repository management.
114-
3. [python](https://www.python.org/) to build and code in Keras.
114+
3. [python](https://www.python.org/) to build and code in TF-Keras.
115115

116116
The following commands check the tools above are successfully installed. Note
117-
that Keras requires at least Python 3.7 to run.
117+
that TF-Keras requires at least Python 3.7 to run.
118118

119119
```shell
120120
bazel --version
@@ -146,7 +146,7 @@ venv_dir\Scripts\activate.bat # for Windows
146146
Clone your forked repo to your local machine. Go to the cloned directory to
147147
install the dependencies into the venv. Since `tf-nightly` uses `keras-nightly`
148148
as a dependency, we need to uninstall `keras-nightly` so that tests will run
149-
against Keras code in the local workspace.
149+
against TF-Keras code in the local workspace.
150150

151151
```shell
152152
git clone https://github.com/YOUR_GITHUB_USERNAME/keras.git
@@ -165,9 +165,9 @@ pip install --upgrade tf-nightly
165165

166166
## Code style
167167

168-
The Keras uses [Black](https://black.readthedocs.io/en/stable/) and
168+
The TF-Keras uses [Black](https://black.readthedocs.io/en/stable/) and
169169
[isort](https://pycqa.github.io/isort/) to format the code. Please refer to
170-
[requirements.txt](https://github.com/keras-team/keras/blob/master/requirements.txt)
170+
[requirements.txt](https://github.com/keras-team/tf-keras/blob/master/requirements.txt)
171171
for the required versions. Run the following command **at the root directory of
172172
the repo** to format your code.
173173

@@ -199,7 +199,7 @@ A **class docstring** may contain the following items:
199199
* Optional `Raises` section for possible errors.
200200

201201
You can check out `MultiHeadAttention` as an example
202-
[(link)](https://github.com/keras-team/keras/blob/v2.12.0-rc1/keras/layers/attention/multi_head_attention.py#L131).
202+
[(link)](https://github.com/keras-team/tf-keras/blob/v2.12.0-rc1/tf_keras/layers/attention/multi_head_attention.py#L131).
203203

204204
A **function docstring** may contain the following items:
205205

@@ -211,7 +211,7 @@ A **function docstring** may contain the following items:
211211
* Optional `Raises` section for possible errors.
212212

213213
You can check out `text_dataset_from_directory` as an example
214-
[(link)](https://github.com/keras-team/keras/blob/v2.12.0-rc1/keras/utils/text_dataset.py#L31).
214+
[(link)](https://github.com/keras-team/tf-keras/blob/v2.12.0-rc1/tf_keras/utils/text_dataset.py#L31).
215215

216216

217217
## Run tests
@@ -267,22 +267,22 @@ command above.
267267
However, it may slow down the tests for not running in parallel
268268
and may cause the test to timeout.
269269

270-
## Contributing to Keras applications
270+
## Contributing to TF-Keras applications
271271

272272
Contributions to the
273273
[pre-trained application library](https://keras.io/api/applications/) are
274-
welcome. Code for Keras applications is located in Keras repository in
275-
[keras/applications](https://github.com/keras-team/keras/blob/master/keras/applications).
276-
When contributing to Keras applications, please keep following checklist in
274+
welcome. Code for TF-Keras applications is located in TF-Keras repository in
275+
[keras/applications](https://github.com/keras-team/tf-keras/blob/master/tf_keras/applications).
276+
When contributing to TF-Keras applications, please keep following checklist in
277277
mind.
278278

279-
- Keras applications must implement an established and widely used model.
279+
- TF-Keras applications must implement an established and widely used model.
280280
Applications should include a link to a paper describing the architecture of
281281
the model with at least 20 citations.
282282
- Applications should be provided with pre-trained weights.
283-
- When submitting a pull request for a Keras application, these weights
283+
- When submitting a pull request for a TF-Keras application, these weights
284284
can be provided at any publically available URL (e.g. a personal Cloud
285-
Storage bucket). The weights will be uploaded to a Keras storage bucket
285+
Storage bucket). The weights will be uploaded to a TF-Keras storage bucket
286286
while merging the pull request.
287287
- Weights should be downloaded with the
288288
[get_file()](https://keras.io/api/utils/python_utils/#getfile-function)
@@ -312,5 +312,5 @@ mind.
312312

313313
## Security vulnerability reports
314314

315-
Since Keras is the high-level API of TensorFlow 2, Keras follows same security practices as TensorFlow.
315+
Since TF-Keras is the high-level API of TensorFlow 2, TF-Keras follows same security practices as TensorFlow.
316316
For details on guidelines on vulnerabilities and reporting them, you can refer [Using TensorFlow Securely](https://github.com/tensorflow/tensorflow/blob/master/SECURITY.md).

ISSUE_TEMPLATE.md

+2-2
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ If you open a GitHub issue, here is our policy:
88
documentation (for small docs fixes please send a PR instead).
99
2. The form below must be filled out.
1010

11-
**Here's why we have that policy**: Keras developers respond to issues. We want to focus on work that benefits the whole community, e.g., fixing bugs and adding features. Support only helps individuals. GitHub also notifies thousands of people when issues are filed. We want them to see you communicating an interesting problem, rather than being redirected to Stack Overflow.
11+
**Here's why we have that policy**: TF-Keras developers respond to issues. We want to focus on work that benefits the whole community, e.g., fixing bugs and adding features. Support only helps individuals. GitHub also notifies thousands of people when issues are filed. We want them to see you communicating an interesting problem, rather than being redirected to Stack Overflow.
1212

1313
------------------------
1414

@@ -35,7 +35,7 @@ python -c "import tensorflow as tf; print(tf.version.GIT_VERSION, tf.version.VER
3535
```
3636

3737
### Describe the problem
38-
Describe the problem clearly here. Be sure to convey here why it's a bug in Keras or why the requested feature is needed.
38+
Describe the problem clearly here. Be sure to convey here why it's a bug in TF-Keras or why the requested feature is needed.
3939

4040
### Source code / logs
4141
Include any logs or source code that would be helpful to diagnose the problem. If including tracebacks, please include the full traceback. Large logs and files should be attached. Try to provide a reproducible test case that is the bare minimum necessary to generate the problem.

README.md

+25-25
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
![Keras logo](https://s3.amazonaws.com/keras.io/img/keras-logo-2018-large-1200.png)
44

5-
This repository hosts the development of the Keras library.
5+
This repository hosts the development of the TF-Keras library.
66
Read the documentation at [keras.io](https://keras.io/).
77

88
## About Keras
@@ -12,26 +12,26 @@ running on top of the machine learning platform [TensorFlow](https://github.com/
1212
It was developed with a focus on enabling fast experimentation and
1313
providing a delightful developer experience.
1414

15-
**The purpose of Keras is to give an *unfair advantage* to any developer looking to ship ML-powered apps.**
15+
**The purpose of TF-Keras is to give an *unfair advantage* to any developer looking to ship ML-powered apps.**
1616

1717
Keras is:
1818

19-
- **Simple** -- but not simplistic. Keras reduces developer *cognitive load*
19+
- **Simple** -- but not simplistic. TF-Keras reduces developer *cognitive load*
2020
to free you to focus on the parts of the problem that really matter.
21-
Keras focuses on ease of use, debugging speed, code elegance & conciseness,
21+
TF-Keras focuses on ease of use, debugging speed, code elegance & conciseness,
2222
maintainability, and deployability (via TFServing, TFLite, TF.js).
23-
- **Flexible** -- Keras adopts the principle of *progressive disclosure of
23+
- **Flexible** -- TF-Keras adopts the principle of *progressive disclosure of
2424
complexity*: simple workflows should be quick and easy, while arbitrarily
2525
advanced workflows should be *possible* via a clear path that builds upon
2626
what you've already learned.
27-
- **Powerful** -- Keras provides industry-strength performance and
27+
- **Powerful** -- TF-Keras provides industry-strength performance and
2828
scalability: it is used by organizations and companies including NASA,
2929
YouTube, and Waymo. That's right -- your YouTube recommendations are
3030
powered by Keras, and so is the world's most advanced driverless vehicle.
3131

3232
---
3333

34-
## Keras & TensorFlow 2
34+
## TF-Keras & TensorFlow 2
3535

3636
[TensorFlow 2](https://www.tensorflow.org/) is an end-to-end, open-source machine learning platform.
3737
You can think of it as an infrastructure layer for
@@ -49,14 +49,14 @@ with a focus on modern deep learning. It provides essential abstractions and bui
4949
and shipping machine learning solutions with high iteration velocity.
5050

5151
Keras empowers engineers and researchers to take full advantage of the scalability
52-
and cross-platform capabilities of TensorFlow 2: you can run Keras on TPU or on large clusters of GPUs,
53-
and you can export your Keras models to run in the browser or on a mobile device.
52+
and cross-platform capabilities of TensorFlow 2: you can run TF-Keras on TPU or on large clusters of GPUs,
53+
and you can export your TF-Keras models to run in the browser or on a mobile device.
5454

5555
---
5656

5757
## First contact with Keras
5858

59-
The core data structures of Keras are __layers__ and __models__.
59+
The core data structures of TF-Keras are __layers__ and __models__.
6060
The simplest type of model is the [`Sequential` model](https://keras.io/guides/sequential_model/), a linear stack of layers.
6161
For more complex architectures, you should use the [Keras functional API](https://keras.io/guides/functional_api/),
6262
which allows you to build arbitrary graphs of layers or [write models entirely from scratch via subclassing](https://keras.io/guides/making_new_layers_and_models_via_subclassing/).
@@ -86,7 +86,7 @@ model.compile(loss='categorical_crossentropy',
8686
metrics=['accuracy'])
8787
```
8888

89-
If you need to, you can further configure your optimizer. The Keras philosophy is to keep simple things simple,
89+
If you need to, you can further configure your optimizer. The TF-Keras philosophy is to keep simple things simple,
9090
while allowing the user to be fully in control when they need to be (the ultimate control being the easy extensibility of the source code via subclassing).
9191

9292
```python
@@ -114,16 +114,16 @@ Or generate predictions on new data:
114114
classes = model.predict(x_test, batch_size=128)
115115
```
116116

117-
What you just saw is the most elementary way to use Keras.
117+
What you just saw is the most elementary way to use TF-Keras.
118118

119-
However, Keras is also a highly-flexible framework suitable to iterate on state-of-the-art research ideas.
119+
However, TF-Keras is also a highly-flexible framework suitable to iterate on state-of-the-art research ideas.
120120
Keras follows the principle of **progressive disclosure of complexity**: it makes it easy to get started,
121121
yet it makes it possible to handle arbitrarily advanced use cases,
122122
only requiring incremental learning at each step.
123123

124124
In pretty much the same way that you were able to train & evaluate a simple neural network above in a few lines,
125-
you can use Keras to quickly develop new training procedures or exotic model architectures.
126-
Here's a low-level training loop example, combining Keras functionality with the TensorFlow `GradientTape`:
125+
you can use TF-Keras to quickly develop new training procedures or exotic model architectures.
126+
Here's a low-level training loop example, combining TF-Keras functionality with the TensorFlow `GradientTape`:
127127

128128
```python
129129
import tensorflow as tf
@@ -150,8 +150,8 @@ for inputs, targets in dataset:
150150

151151
For more in-depth tutorials about Keras, you can check out:
152152

153-
- [Introduction to Keras for engineers](https://keras.io/getting_started/intro_to_keras_for_engineers/)
154-
- [Introduction to Keras for researchers](https://keras.io/getting_started/intro_to_keras_for_researchers/)
153+
- [Introduction to TF-Keras for engineers](https://keras.io/getting_started/intro_to_keras_for_engineers/)
154+
- [Introduction to TF-Keras for researchers](https://keras.io/getting_started/intro_to_keras_for_researchers/)
155155
- [Developer guides](https://keras.io/guides/)
156156
- [Other learning resources](https://keras.io/getting_started/learning_resources/)
157157

@@ -161,10 +161,10 @@ For more in-depth tutorials about Keras, you can check out:
161161

162162
Keras comes packaged with TensorFlow 2 as `tensorflow.keras`.
163163
To start using Keras, simply [install TensorFlow 2](https://www.tensorflow.org/install).
164-
You can then import Keras as follows:
164+
You can then import TF-Keras as follows:
165165

166166
```python
167-
from tensorflow import keras
167+
from tensorflow import tf_keras as keras
168168
```
169169

170170
---
@@ -173,7 +173,7 @@ from tensorflow import keras
173173

174174
Keras has **nightly releases** (`keras-nightly` on PyPI)
175175
and **stable releases** (`keras` on PyPI).
176-
The nightly Keras releases are usually compatible with the corresponding version
176+
The nightly TF-Keras releases are usually compatible with the corresponding version
177177
of the `tf-nightly` releases
178178
(e.g. `keras-nightly==2.7.0.dev2021100607` should be
179179
used with `tf-nightly==2.7.0.dev2021100607`).
@@ -182,11 +182,11 @@ For stable releases, each Keras
182182
version maps to a specific stable version of TensorFlow.
183183

184184
The table below shows the compatibility version mapping
185-
between TensorFlow versions and Keras versions.
185+
between TensorFlow versions and TF-Keras versions.
186186

187-
All the release branches can be found on [GitHub](https://github.com/keras-team/keras/releases).
187+
All the release branches can be found on [GitHub](https://github.com/keras-team/tf-keras/releases).
188188

189-
All the release binaries can be found on [Pypi](https://pypi.org/project/keras/#history).
189+
All the release binaries can be found on [Pypi](https://pypi.org/project/tf_keras/#history).
190190

191191
---
192192
## Support
@@ -201,13 +201,13 @@ You can ask questions and join the development discussion:
201201
## Opening an issue
202202

203203
You can also post **bug reports and feature requests** (only)
204-
in [GitHub issues](https://github.com/keras-team/keras/issues).
204+
in [GitHub issues](https://github.com/keras-team/tf-keras/issues).
205205

206206

207207
---
208208

209209
## Opening a PR
210210

211211
We welcome contributions! Before opening a PR, please read
212-
[our contributor guide](https://github.com/keras-team/keras/blob/master/CONTRIBUTING.md),
212+
[our contributor guide](https://github.com/keras-team/tf-keras/blob/master/CONTRIBUTING.md),
213213
and the [API design guideline](https://github.com/keras-team/governance/blob/master/keras_api_design_guidelines.md).

0 commit comments

Comments
 (0)