Skip to content

Commit 269d228

Browse files
authored
Update README.md
1 parent 151837a commit 269d228

File tree

1 file changed

+11
-1
lines changed

1 file changed

+11
-1
lines changed

README.md

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -87,7 +87,7 @@ trainA = trainA.map(Image_Data_Class.image_processing, num_parallel_calls=8)
8787

8888
```
8989

90-
* Personally recommend `num_parallel_calls` = `4 or 8`
90+
* Personally recommend `num_parallel_calls` = `8 or 16`
9191

9292
***
9393

@@ -108,6 +108,16 @@ trainA = trainA.shuffle(buffer_size=10000).prefetch(buffer_size=batch_size).batc
108108
trainA = trainA.shuffle(10000).prefetch(batch_size).apply(batch_and_drop_remainder(batch_size)).repeat()
109109
```
110110

111+
* If you use the `tensorflow 1.8`, then this is more fast
112+
```python
113+
# hyper-parameter examples
114+
gpu_device = '/gpu:0'
115+
dataset_num = 10000
116+
batch_size = 8
117+
118+
trainA = trainA.apply(shuffle_and_repeat(dataset_num)).apply(map_and_batch(Image_Data_Class.image_processing, batch_size, num_parallel_batches=16, drop_remainder=True)).apply(prefetch_to_device(gpu_device, batch_size))
119+
```
120+
111121
***
112122

113123
### 5. Set `Iterator`

0 commit comments

Comments
 (0)