Skip to content

Commit c7827bd

Browse files
authored
Merge pull request #1468 from rstudio/retether-3.5.0
Retether-3.5.0
2 parents 64cd480 + 73a3617 commit c7827bd

File tree

1,106 files changed

+5517
-3180
lines changed

Some content is hidden

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

1,106 files changed

+5517
-3180
lines changed

.tether/man/InputLayer.txt

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -41,6 +41,8 @@ class InputLayer(keras.src.layers.layer.Layer)
4141
| ----------------------------------------------------------------------
4242
| Readonly properties defined here:
4343
|
44+
| batch_shape
45+
|
4446
| dtype
4547
| Alias of `layer.variable_dtype`.
4648
|

.tether/man/Layer.txt

Lines changed: 19 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -173,6 +173,9 @@ class Layer(keras.src.backend.tensorflow.layer.TFLayer, keras.src.ops.operation.
173173
| )
174174
| Call self as a function.
175175
|
176+
| __delattr__(self, name)
177+
| Implement delattr(self, name).
178+
|
176179
| __init__(
177180
| self,
178181
| *,
@@ -211,7 +214,11 @@ class Layer(keras.src.backend.tensorflow.layer.TFLayer, keras.src.ops.operation.
211214
| return x
212215
| ```
213216
|
214-
| add_metric(self)
217+
| add_metric(
218+
| self,
219+
| *args,
220+
| **kwargs
221+
| )
215222
|
216223
| add_variable(
217224
| self,
@@ -347,7 +354,17 @@ class Layer(keras.src.backend.tensorflow.layer.TFLayer, keras.src.ops.operation.
347354
| Args:
348355
| store: Dict from which the state of the model will be loaded.
349356
|
350-
| quantize(self, mode)
357+
| quantize(
358+
| self,
359+
| mode,
360+
| type_check=True
361+
| )
362+
|
363+
| quantized_build(
364+
| self,
365+
| input_shape,
366+
| mode
367+
| )
351368
|
352369
| quantized_call(
353370
| self,

.tether/man/Loss.txt

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,17 @@ class Loss(keras.src.saving.keras_saveable.KerasSaveable)
55
|
66
| Loss base class.
77
|
8+
| Args:
9+
| reduction: Type of reduction to apply to the loss. In almost all cases
10+
| this should be `"sum_over_batch_size"`.
11+
| Supported options are `"sum"`, `"sum_over_batch_size"` or `None`.
12+
| name: Optional name for the loss instance.
13+
| dtype: The dtype of the loss's computations. Defaults to `None`, which
14+
| means using `keras.backend.floatx()`. `keras.backend.floatx()` is a
15+
| `"float32"` unless set to different value
16+
| (via `keras.backend.set_floatx()`). If a `keras.DTypePolicy` is
17+
| provided, then the `compute_dtype` will be utilized.
18+
|
819
| To be implemented by subclasses:
920
|
1021
| * `call()`: Contains the logic for loss calculation using `y_true`,
@@ -54,4 +65,9 @@ class Loss(keras.src.saving.keras_saveable.KerasSaveable)
5465
|
5566
| from_config(config)
5667
|
68+
| ----------------------------------------------------------------------
69+
| Readonly properties defined here:
70+
|
71+
| dtype
72+
|
5773

.tether/man/Metric.txt

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,8 +6,12 @@ class Metric(keras.src.saving.keras_saveable.KerasSaveable)
66
| Encapsulates metric logic and state.
77
|
88
| Args:
9-
| name: (Optional) string name of the metric instance.
10-
| dtype: (Optional) data type of the metric result.
9+
| name: Optional name for the metric instance.
10+
| dtype: The dtype of the metric's computations. Defaults to `None`, which
11+
| means using `keras.backend.floatx()`. `keras.backend.floatx()` is a
12+
| `"float32"` unless set to different value
13+
| (via `keras.backend.set_floatx()`). If a `keras.DTypePolicy` is
14+
| provided, then the `compute_dtype` will be utilized.
1115
|
1216
| Example:
1317
|

.tether/man/audio_dataset_from_directory.txt

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -73,8 +73,9 @@ Args:
7373
length of the longest sequence in the batch.
7474
ragged: Whether to return a Ragged dataset (where each sequence has its
7575
own length). Defaults to `False`.
76-
shuffle: Whether to shuffle the data. Defaults to `True`.
76+
shuffle: Whether to shuffle the data.
7777
If set to `False`, sorts the data in alphanumeric order.
78+
Defaults to `True`.
7879
seed: Optional random seed for shuffling and transformations.
7980
validation_split: Optional float between 0 and 1, fraction of data to
8081
reserve for validation.

.tether/man/callback_backup_and_restore.txt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -59,11 +59,11 @@ class BackupAndRestore(keras.src.callbacks.callback.Callback)
5959
| When set to an integer, the callback saves the checkpoint every
6060
| `save_freq` batches. Set `save_freq=False` only if using
6161
| preemption checkpointing (i.e. with `save_before_preemption=True`).
62-
| delete_checkpoint: Boolean, defaults to `True`. This `BackupAndRestore`
62+
| delete_checkpoint: Boolean. This `BackupAndRestore`
6363
| callback works by saving a checkpoint to back up the training state.
6464
| If `delete_checkpoint=True`, the checkpoint will be deleted after
6565
| training is finished. Use `False` if you'd like to keep the checkpoint
66-
| for future usage.
66+
| for future usage. Defaults to `True`.
6767
|
6868
| Method resolution order:
6969
| BackupAndRestore

.tether/man/image_dataset_from_directory.txt

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -68,15 +68,15 @@ Args:
6868
(must match names of subdirectories). Used to control the order
6969
of the classes (otherwise alphanumerical order is used).
7070
color_mode: One of `"grayscale"`, `"rgb"`, `"rgba"`.
71-
Defaults to `"rgb"`. Whether the images will be converted to
72-
have 1, 3, or 4 channels.
71+
Whether the images will be converted to
72+
have 1, 3, or 4 channels. Defaults to `"rgb"`.
7373
batch_size: Size of the batches of data. Defaults to 32.
7474
If `None`, the data will not be batched
7575
(the dataset will yield individual samples).
7676
image_size: Size to resize images to after they are read from disk,
77-
specified as `(height, width)`. Defaults to `(256, 256)`.
77+
specified as `(height, width)`.
7878
Since the pipeline processes batches of images that must all have
79-
the same size, this must be provided.
79+
the same size, this must be provided. Defaults to `(256, 256)`.
8080
shuffle: Whether to shuffle the data. Defaults to `True`.
8181
If set to `False`, sorts the data in alphanumeric order.
8282
seed: Optional random seed for shuffling and transformations.
@@ -88,9 +88,10 @@ Args:
8888
When `subset="both"`, the utility returns a tuple of two datasets
8989
(the training and validation datasets respectively).
9090
interpolation: String, the interpolation method used when
91-
resizing images. Defaults to `"bilinear"`.
91+
resizing images.
9292
Supports `"bilinear"`, `"nearest"`, `"bicubic"`, `"area"`,
9393
`"lanczos3"`, `"lanczos5"`, `"gaussian"`, `"mitchellcubic"`.
94+
Defaults to `"bilinear"`.
9495
follow_links: Whether to visit subdirectories pointed to by symlinks.
9596
Defaults to `False`.
9697
crop_to_aspect_ratio: If `True`, resize the images without aspect

.tether/man/image_smart_resize.txt

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -56,9 +56,9 @@ Args:
5656
or `(batch_size, height, width, channels)`.
5757
size: Tuple of `(height, width)` integer. Target size.
5858
interpolation: String, interpolation to use for resizing.
59-
Defaults to `'bilinear'`.
60-
Supports `bilinear`, `nearest`, `bicubic`,
61-
`lanczos3`, `lanczos5`.
59+
Supports `"bilinear"`, `"nearest"`, `"bicubic"`,
60+
`"lanczos3"`, `"lanczos5"`.
61+
Defaults to `"bilinear"`.
6262
data_format: `"channels_last"` or `"channels_first"`.
6363
backend_module: Backend module to use (if different from the default
6464
backend).
@@ -68,3 +68,4 @@ Returns:
6868
If the input image was a NumPy array, the output is a NumPy array,
6969
and if it was a backend-native tensor,
7070
the output is a backend-native tensor.
71+

.tether/man/keras.distribution.txt

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,8 @@
1-
DataParallel(device_mesh=None, devices=None)
1+
DataParallel(
2+
device_mesh=None,
3+
devices=None,
4+
auto_shard_dataset=True
5+
)
26
DeviceMesh(
37
shape,
48
axis_names,

.tether/man/keras.layers.txt

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1247,7 +1247,11 @@ UpSampling3D(
12471247
**kwargs
12481248
)
12491249
Wrapper(layer, **kwargs)
1250-
ZeroPadding1D(padding=1, **kwargs)
1250+
ZeroPadding1D(
1251+
padding=1,
1252+
data_format=None,
1253+
**kwargs
1254+
)
12511255
ZeroPadding2D(
12521256
padding=(1, 1),
12531257
data_format=None,

0 commit comments

Comments
 (0)