Skip to content

Commit

Permalink
Adding link for pretrained FP32 and INT8 models (#197)
Browse files Browse the repository at this point in the history
Adding link for Kaggle Display Advertising Challenge Dataset download

Signed-off-by: Rajendrakumar Chinnaiyan <rajendrakumar.chinnaiyan@intel.com>
  • Loading branch information
rchinna authored and claynerobison committed Feb 26, 2019
1 parent 8cad7da commit 1e22b92
Showing 1 changed file with 29 additions and 27 deletions.
56 changes: 29 additions & 27 deletions benchmarks/recommendation/tensorflow/wide_deep_large_ds/README.md
100644 → 100755
Original file line number Diff line number Diff line change
Expand Up @@ -11,25 +11,26 @@ Benchmarking instructions and scripts for model training coming later.
## INT8 Inference Instructions


1. Download large <> dataset income dataset from <>:

To be updated post dataset approval

1. Download large Kaggle Display Advertising Challenge Dataset from
http://labs.criteo.com/2014/02/kaggle-display-advertising-challenge-dataset/

2. Pre-process the downloaded dataset to tfrecords using [preprocess_csv_tfrecords.py](/models/recommendation/tensorflow/wide_deep_large_ds/dataset/preprocess_csv_tfrecords.py)

```
$ python3.6 preprocess_csv_tfrecords.py --csv-datafile eval.csv
$ python3.6 preprocess_csv_tfrecords.py --csv-datafile eval.csv
```
3. Download and extract the pre-trained model.
```
$ wget https://storage.googleapis.com/intel-optimized-tensorflow/models/wide_deep_int8_pretrained_model.pb
```
3. Clone the [intelai/models](https://github.com/intelai/models) repo.
4. Clone the [intelai/models](https://github.com/intelai/models) repo.
This repo has the launch script for running benchmarks, which we will
use in the next step.
```
$ git clone https://github.com/IntelAI/models.git
```
4. How to run benchmarks
5. How to run benchmarks
* Running benchmarks in latency mode, set `--batch-size 1`
```
Expand All @@ -44,7 +45,7 @@ Benchmarking instructions and scripts for model training coming later.
--batch-size 1 \
--socket-id 0 \
--docker-image tensorflow/tensorflow:latest-mkl \
--in-graph /root/user/wide_deep_files/int8_wide_deep_final.pb \
--in-graph /root/user/wide_deep_files/wide_deep_int8_pretrained_model.pb \
--data-location /root/user/wide_deep_files/preprocessed_eval.tfrecords
```
* Running benchmarks in throughput mode, set `--batch-size 1024`
Expand All @@ -60,7 +61,7 @@ Benchmarking instructions and scripts for model training coming later.
--batch-size 1024 \
--socket-id 0 \
--docker-image tensorflow/tensorflow:latest-mkl \
--in-graph /root/user/wide_deep_files/int8_wide_deep_final.pb \
--in-graph /root/user/wide_deep_files/wide_deep_int8_pretrained_model.pb \
--data-location /root/user/wide_deep_files/preprocessed_eval.tfrecords
```
6. The log file is saved to the value of `--output-dir`.
Expand All @@ -69,7 +70,6 @@ Benchmarking instructions and scripts for model training coming later.
something like this:
```
--------------------------------------------------
Total test records : 2000000
No of correct predicitons : 1549508
Expand All @@ -80,31 +80,33 @@ Benchmarking instructions and scripts for model training coming later.
Latency (millisecond/batch) : 0.000988
Throughput is (records/sec) : 1151892.25
--------------------------------------------------
numactl --cpunodebind=0 --membind=0 python /workspace/intelai_models/int8/inference.py --input-graph=/in_graph/int8_wide_deep_final.pb --inter-op-parallelism-threads=28 --intra-op-parallelism-threads=1 --omp-num-threads=1 --batch-size=1024 --kmp-blocktime=0 --datafile-path=/dataset
numactl --cpunodebind=0 --membind=0 python /workspace/intelai_models/int8/inference.py --input-graph=/in_graph/wide_deep_int8_pretrained_model.pb --inter-op-parallelism-threads=28 --intra-op-parallelism-threads=1 --omp-num-threads=1 --batch-size=1024 --kmp-blocktime=0 --datafile-path=/dataset
Ran inference with batch size 1024
Log location outside container: {--output-dir value}/benchmark_wide_deep_large_ds_inference_int8_20190225_061815.log
```
## FP32 Inference Instructions
1. Download large <> dataset income dataset from <>:
To be updated post dataset approval
2. Pre-process the downloaded dataset to tfrecords using [preprocess_csv_tfrecords.py](../../../../models/recommendation/tensorflow/wide_deep_large_ds/dataset/preprocess_csv_tfrecords.py)
```
$ python3.6 preprocess_csv_tfrecords.py --csv-datafile eval.csv
```
3. Clone the [intelai/models](https://github.com/intelai/models) repo.
1. Download large Kaggle Display Advertising Challenge Dataset from
http://labs.criteo.com/2014/02/kaggle-display-advertising-challenge-dataset/
2. Pre-process the downloaded dataset to tfrecords using [preprocess_csv_tfrecords.py](/models/recommendation/tensorflow/wide_deep_large_ds/dataset/preprocess_csv_tfrecords.py)
```
$ python3.6 preprocess_csv_tfrecords.py --csv-datafile eval.csv
```
3. Download and extract the pre-trained model.
```
$ wget https://storage.googleapis.com/intel-optimized-tensorflow/models/wide_deep_fp32_pretrained_model.pb
```
4. Clone the [intelai/models](https://github.com/intelai/models) repo.
This repo has the launch script for running benchmarks, which we will
use in the next step.
```
$ git clone https://github.com/IntelAI/models.git
```
4. How to run benchmarks
5. How to run benchmarks
* Running benchmarks in latency mode, set `--batch-size 1`
```
Expand All @@ -119,7 +121,7 @@ Benchmarking instructions and scripts for model training coming later.
--batch-size 1 \
--socket-id 0 \
--docker-image tensorflow/tensorflow:latest-mkl \
--in-graph /root/user/wide_deep_files/fp32_wide_deep_final.pb \
--in-graph /root/user/wide_deep_files/wide_deep_fp32_pretrained_model.pb \
--data-location /root/user/wide_deep_files/preprocessed_eval.tfrecords
```
* Running benchmarks in throughput mode, set `--batch-size 1024`
Expand All @@ -135,7 +137,7 @@ Benchmarking instructions and scripts for model training coming later.
--batch-size 1024 \
--socket-id 0 \
--docker-image tensorflow/tensorflow:latest-mkl \
--in-graph /root/user/wide_deep_files/fp32_wide_deep_final.pb \
--in-graph /root/user/wide_deep_files/wide_deep_fp32_pretrained_model.pb \
--data-location /root/user/wide_deep_files/preprocessed_eval.tfrecords
```
6. The log file is saved to the value of `--output-dir`.
Expand All @@ -155,7 +157,7 @@ Benchmarking instructions and scripts for model training coming later.
Latency (millisecond/batch) : 0.001749
Throughput is (records/sec) : 571802.228
--------------------------------------------------
numactl --cpunodebind=0 --membind=0 python /workspace/intelai_models/int8/inference.py --input-graph=/in_graph/fp32_wide_deep_final.pb --inter-op-parallelism-threads=28 --intra-op-parallelism-threads=1 --omp-num-threads=1 --batch-size=1024 --kmp-blocktime=0 --datafile-path=/dataset
numactl --cpunodebind=0 --membind=0 python /workspace/intelai_models/int8/inference.py --input-graph=/in_graph/wide_deep_fp32_pretrained_model.pb --inter-op-parallelism-threads=28 --intra-op-parallelism-threads=1 --omp-num-threads=1 --batch-size=1024 --kmp-blocktime=0 --datafile-path=/dataset
Ran inference with batch size 1024
Log location outside container: {--output-dir value}/benchmark_wide_deep_large_ds_inference_fp32_20190225_062206.log
Expand Down

0 comments on commit 1e22b92

Please sign in to comment.