Skip to content

Commit 9a9b6e6

Browse files
committed
Remove unnecessary logs
1 parent 214a31e commit 9a9b6e6

File tree

4 files changed

+59
-112
lines changed

4 files changed

+59
-112
lines changed

examples/generative/md/fine_tune_via_textual_inversion.md

Lines changed: 0 additions & 109 deletions
Original file line numberDiff line numberDiff line change
@@ -64,107 +64,6 @@ stable_diffusion = keras_cv.models.StableDiffusion()
6464
```
6565
<div class="k-default-codeblock">
6666
```
67-
--- Logging error ---
68-
Traceback (most recent call last):
69-
File "/home/lukewood/.local/lib/python3.7/site-packages/pip/_internal/utils/logging.py", line 177, in emit
70-
self.console.print(renderable, overflow="ignore", crop=False, style=style)
71-
File "/home/lukewood/.local/lib/python3.7/site-packages/pip/_vendor/rich/console.py", line 1673, in print
72-
extend(render(renderable, render_options))
73-
File "/home/lukewood/.local/lib/python3.7/site-packages/pip/_vendor/rich/console.py", line 1305, in render
74-
for render_output in iter_render:
75-
File "/home/lukewood/.local/lib/python3.7/site-packages/pip/_internal/utils/logging.py", line 134, in __rich_console__
76-
for line in lines:
77-
File "/home/lukewood/.local/lib/python3.7/site-packages/pip/_vendor/rich/segment.py", line 249, in split_lines
78-
for segment in segments:
79-
File "/home/lukewood/.local/lib/python3.7/site-packages/pip/_vendor/rich/console.py", line 1283, in render
80-
renderable = rich_cast(renderable)
81-
File "/home/lukewood/.local/lib/python3.7/site-packages/pip/_vendor/rich/protocol.py", line 36, in rich_cast
82-
renderable = cast_method()
83-
File "/home/lukewood/.local/lib/python3.7/site-packages/pip/_internal/self_outdated_check.py", line 130, in __rich__
84-
pip_cmd = get_best_invocation_for_this_pip()
85-
File "/home/lukewood/.local/lib/python3.7/site-packages/pip/_internal/utils/entrypoints.py", line 60, in get_best_invocation_for_this_pip
86-
os.path.join(binary_prefix, exe_name),
87-
File "/usr/lib/python3.7/genericpath.py", line 97, in samefile
88-
s2 = os.stat(f2)
89-
FileNotFoundError: [Errno 2] No such file or directory: '/usr/bin/pip'
90-
Call stack:
91-
File "/home/lukewood/.local/bin/pip", line 10, in <module>
92-
sys.exit(main())
93-
File "/home/lukewood/.local/lib/python3.7/site-packages/pip/_internal/cli/main.py", line 70, in main
94-
return command.main(cmd_args)
95-
File "/home/lukewood/.local/lib/python3.7/site-packages/pip/_internal/cli/base_command.py", line 101, in main
96-
return self._main(args)
97-
File "/home/lukewood/.local/lib/python3.7/site-packages/pip/_internal/cli/base_command.py", line 223, in _main
98-
self.handle_pip_version_check(options)
99-
File "/home/lukewood/.local/lib/python3.7/site-packages/pip/_internal/cli/req_command.py", line 190, in handle_pip_version_check
100-
pip_self_version_check(session, options)
101-
File "/home/lukewood/.local/lib/python3.7/site-packages/pip/_internal/self_outdated_check.py", line 236, in pip_self_version_check
102-
logger.warning("[present-rich] %s", upgrade_prompt)
103-
File "/usr/lib/python3.7/logging/__init__.py", line 1395, in warning
104-
self._log(WARNING, msg, args, **kwargs)
105-
File "/usr/lib/python3.7/logging/__init__.py", line 1519, in _log
106-
self.handle(record)
107-
File "/usr/lib/python3.7/logging/__init__.py", line 1529, in handle
108-
self.callHandlers(record)
109-
File "/usr/lib/python3.7/logging/__init__.py", line 1591, in callHandlers
110-
hdlr.handle(record)
111-
File "/usr/lib/python3.7/logging/__init__.py", line 905, in handle
112-
self.emit(record)
113-
File "/home/lukewood/.local/lib/python3.7/site-packages/pip/_internal/utils/logging.py", line 179, in emit
114-
self.handleError(record)
115-
Message: '[present-rich] %s'
116-
Arguments: (UpgradePrompt(old='22.2.2', new='22.3.1'),)
117-
--- Logging error ---
118-
Traceback (most recent call last):
119-
File "/home/lukewood/.local/lib/python3.7/site-packages/pip/_internal/utils/logging.py", line 177, in emit
120-
self.console.print(renderable, overflow="ignore", crop=False, style=style)
121-
File "/home/lukewood/.local/lib/python3.7/site-packages/pip/_vendor/rich/console.py", line 1673, in print
122-
extend(render(renderable, render_options))
123-
File "/home/lukewood/.local/lib/python3.7/site-packages/pip/_vendor/rich/console.py", line 1305, in render
124-
for render_output in iter_render:
125-
File "/home/lukewood/.local/lib/python3.7/site-packages/pip/_internal/utils/logging.py", line 134, in __rich_console__
126-
for line in lines:
127-
File "/home/lukewood/.local/lib/python3.7/site-packages/pip/_vendor/rich/segment.py", line 249, in split_lines
128-
for segment in segments:
129-
File "/home/lukewood/.local/lib/python3.7/site-packages/pip/_vendor/rich/console.py", line 1283, in render
130-
renderable = rich_cast(renderable)
131-
File "/home/lukewood/.local/lib/python3.7/site-packages/pip/_vendor/rich/protocol.py", line 36, in rich_cast
132-
renderable = cast_method()
133-
File "/home/lukewood/.local/lib/python3.7/site-packages/pip/_internal/self_outdated_check.py", line 130, in __rich__
134-
pip_cmd = get_best_invocation_for_this_pip()
135-
File "/home/lukewood/.local/lib/python3.7/site-packages/pip/_internal/utils/entrypoints.py", line 60, in get_best_invocation_for_this_pip
136-
os.path.join(binary_prefix, exe_name),
137-
File "/usr/lib/python3.7/genericpath.py", line 97, in samefile
138-
s2 = os.stat(f2)
139-
FileNotFoundError: [Errno 2] No such file or directory: '/usr/bin/pip'
140-
Call stack:
141-
File "/home/lukewood/.local/bin/pip", line 10, in <module>
142-
sys.exit(main())
143-
File "/home/lukewood/.local/lib/python3.7/site-packages/pip/_internal/cli/main.py", line 70, in main
144-
return command.main(cmd_args)
145-
File "/home/lukewood/.local/lib/python3.7/site-packages/pip/_internal/cli/base_command.py", line 101, in main
146-
return self._main(args)
147-
File "/home/lukewood/.local/lib/python3.7/site-packages/pip/_internal/cli/base_command.py", line 223, in _main
148-
self.handle_pip_version_check(options)
149-
File "/home/lukewood/.local/lib/python3.7/site-packages/pip/_internal/cli/req_command.py", line 190, in handle_pip_version_check
150-
pip_self_version_check(session, options)
151-
File "/home/lukewood/.local/lib/python3.7/site-packages/pip/_internal/self_outdated_check.py", line 236, in pip_self_version_check
152-
logger.warning("[present-rich] %s", upgrade_prompt)
153-
File "/usr/lib/python3.7/logging/__init__.py", line 1395, in warning
154-
self._log(WARNING, msg, args, **kwargs)
155-
File "/usr/lib/python3.7/logging/__init__.py", line 1519, in _log
156-
self.handle(record)
157-
File "/usr/lib/python3.7/logging/__init__.py", line 1529, in handle
158-
self.callHandlers(record)
159-
File "/usr/lib/python3.7/logging/__init__.py", line 1591, in callHandlers
160-
hdlr.handle(record)
161-
File "/usr/lib/python3.7/logging/__init__.py", line 905, in handle
162-
self.emit(record)
163-
File "/home/lukewood/.local/lib/python3.7/site-packages/pip/_internal/utils/logging.py", line 179, in emit
164-
self.handleError(record)
165-
Message: '[present-rich] %s'
166-
Arguments: (UpgradePrompt(old='22.2.2', new='22.3.1'),)
167-
16867
By using this model checkpoint, you acknowledge that its usage is subject to the terms of the CreativeML Open RAIL-M license at https://raw.githubusercontent.com/CompVis/stable-diffusion/main/LICENSE
16968
17069
```
@@ -326,14 +225,6 @@ train_ds = assemble_dataset(
326225
)
327226
```
328227

329-
<div class="k-default-codeblock">
330-
```
331-
WARNING:tensorflow:From /home/lukewood/.local/lib/python3.7/site-packages/tensorflow/python/autograph/pyct/static_analysis/liveness.py:83: Analyzer.lamba_check (from tensorflow.python.autograph.pyct.static_analysis.liveness) is deprecated and will be removed after 2023-09-23.
332-
Instructions for updating:
333-
Lambda fuctions will be no more assumed to be used in the statement where they are used, or at least in the same block. https://github.com/tensorflow/tensorflow/issues/56089
334-
335-
```
336-
</div>
337228
---
338229
## On the importance of prompt accuracy
339230

scripts/autogen.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,7 @@
3939
EXAMPLES_GH_LOCATION = Path("keras-team") / "keras-io" / "blob" / "master" / "examples"
4040
GUIDES_GH_LOCATION = Path("keras-team") / "keras-io" / "blob" / "master" / "guides"
4141
PROJECT_URL = {
42-
"keras": "https://github.com/keras-team/keras/tree/v2.11.0/",
42+
"keras": "https://github.com/keras-team/keras/tree/v2.12.0/",
4343
"keras_tuner": "https://github.com/keras-team/keras-tuner/tree/1.1.3/",
4444
"keras_cv": "https://github.com/keras-team/keras-cv/tree/v0.3.4/",
4545
"keras_nlp": "https://github.com/keras-team/keras-nlp/tree/v0.3.1/",

scripts/examples_master.py

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -537,6 +537,11 @@
537537
"title": "Denoising Diffusion Probabilistic Models",
538538
"subcategory": "Image generation",
539539
},
540+
{
541+
"path": "fine_tune_via_textual_inversion",
542+
"title": "Teach StableDiffusion new concepts via Textual Inversion",
543+
"subcategory": "Image generation",
544+
},
540545
{
541546
"path": "vae",
542547
"title": "Variational AutoEncoder",

templates/examples/audio/uk_ireland_accent_recognition.md

Lines changed: 53 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -182,6 +182,47 @@ for i in zip_files:
182182
os.remove(zip_file)
183183
```
184184

185+
<div class="k-default-codeblock">
186+
```
187+
Downloading data from https://www.openslr.org/resources/83/line_index_all.csv
188+
1990656/1986139 [==============================] - 1s 0us/step
189+
1998848/1986139 [==============================] - 1s 0us/step
190+
Downloading data from https://www.openslr.org/resources/83/irish_english_male.zip
191+
164536320/164531638 [==============================] - 9s 0us/step
192+
164544512/164531638 [==============================] - 9s 0us/step
193+
Downloading data from https://www.openslr.org/resources/83/midlands_english_female.zip
194+
103088128/103085118 [==============================] - 6s 0us/step
195+
103096320/103085118 [==============================] - 6s 0us/step
196+
Downloading data from https://www.openslr.org/resources/83/midlands_english_male.zip
197+
166838272/166833961 [==============================] - 9s 0us/step
198+
166846464/166833961 [==============================] - 9s 0us/step
199+
Downloading data from https://www.openslr.org/resources/83/northern_english_female.zip
200+
314990592/314983063 [==============================] - 15s 0us/step
201+
314998784/314983063 [==============================] - 15s 0us/step
202+
Downloading data from https://www.openslr.org/resources/83/northern_english_male.zip
203+
817774592/817772034 [==============================] - 39s 0us/step
204+
817782784/817772034 [==============================] - 39s 0us/step
205+
Downloading data from https://www.openslr.org/resources/83/scottish_english_female.zip
206+
351444992/351443880 [==============================] - 17s 0us/step
207+
351453184/351443880 [==============================] - 17s 0us/step
208+
Downloading data from https://www.openslr.org/resources/83/scottish_english_male.zip
209+
620257280/620254118 [==============================] - 30s 0us/step
210+
620265472/620254118 [==============================] - 30s 0us/step
211+
Downloading data from https://www.openslr.org/resources/83/southern_english_female.zip
212+
1636704256/1636701939 [==============================] - 77s 0us/step
213+
1636712448/1636701939 [==============================] - 77s 0us/step
214+
Downloading data from https://www.openslr.org/resources/83/southern_english_male.zip
215+
1700962304/1700955740 [==============================] - 79s 0us/step
216+
1700970496/1700955740 [==============================] - 79s 0us/step
217+
Downloading data from https://www.openslr.org/resources/83/welsh_english_female.zip
218+
595689472/595683538 [==============================] - 29s 0us/step
219+
595697664/595683538 [==============================] - 29s 0us/step
220+
Downloading data from https://www.openslr.org/resources/83/welsh_english_male.zip
221+
757653504/757645790 [==============================] - 37s 0us/step
222+
757661696/757645790 [==============================] - 37s 0us/step
223+
224+
```
225+
</div>
185226
---
186227
## Load the data in a Dataframe
187228

@@ -197,20 +238,25 @@ dataframe.head()
197238
```
198239

199240

241+
242+
200243
<div>
201244
<style scoped>
202245
.dataframe tbody tr th:only-of-type {
203246
vertical-align: middle;
204247
}
205248

249+
<div class="k-default-codeblock">
250+
```
206251
.dataframe tbody tr th {
207252
vertical-align: top;
208253
}
209254

210255
.dataframe thead th {
211256
text-align: right;
212257
}
213-
258+
```
259+
</div>
214260
</style>
215261
<table border="1" class="dataframe">
216262
<thead>
@@ -288,20 +334,25 @@ dataframe.head()
288334
```
289335

290336

337+
338+
291339
<div>
292340
<style scoped>
293341
.dataframe tbody tr th:only-of-type {
294342
vertical-align: middle;
295343
}
296344

345+
<div class="k-default-codeblock">
346+
```
297347
.dataframe tbody tr th {
298348
vertical-align: top;
299349
}
300350

301351
.dataframe thead th {
302352
text-align: right;
303353
}
304-
354+
```
355+
</div>
305356
</style>
306357
<table border="1" class="dataframe">
307358
<thead>

0 commit comments

Comments
 (0)