Skip to content

Add page for BERT workload#9

Open
taehoonlee-desilo wants to merge 2 commits into
fhe-benchmarking:mainfrom
Desilo:bert
Open

Add page for BERT workload#9
taehoonlee-desilo wants to merge 2 commits into
fhe-benchmarking:mainfrom
Desilo:bert

Conversation

@taehoonlee-desilo

Copy link
Copy Markdown

No description provided.

@andreea-alexandru andreea-alexandru left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good, needs some small fixes.

Comment thread BERT/index.html Outdated
Comment thread BERT/index.html
{0,1,2,3} Instance size (0-single/1-small/2-medium/3-large)

options:
-h, --help show this help message and exit

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The arguments should reflect the ones in https://github.com/fhe-benchmarking/BERT/blob/main/harness/utils.py. The README of the BERT repo should also be updated.

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Currently we only have one model and one dataset, thus we (DESILO) and @code-perspective discussed removing the relevant explanation as shown in here.

(Although it was a mistake not to remove that part from utils.py), We already remove the model/dataset arguments in the README. Thus, I would like to hear your thoughts on whether it would be better to add the arguments again, even if only one option is actually supported.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you for providing the context. It is fine to not have the model and dataset arguments at the moment, as long as the README, description, and actual options are all consistent.

Comment thread BERT/index.html Outdated
Comment thread BERT/index.html

<p>Submissions are also required to meet the quality bar of <b>correct inference</b> result for single inference and <b>at least 75% accuracy</b> for batch inference.
</p>

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please describe the BERT model a bit more, e.g., BERT-Base 110M. Mention that other models or datasets may be added in the future.

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The BERT description has been updated. And the issue about model/dataset is mentioned as the above comment.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I would still add a sentence on "Additional models and datasets may be added in the future."

Comment thread BERT/Large.html
<th id="col21" class="server-timing-header" title="Total Time">Total</th>
<th id="col22" class="server-timing-header" title="Dataset generation">DB Gen</th>
<th id="col23" class="server-timing-header" title="Key Generation">Keygen</th>
<th id="col24" class="server-timing-header" title="Encrypted model preprocessing">Model Prep</th>

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The server reported times from the measurements in the repo is I/O, not Model Prep. At the same time, it's worth unhiding the Model Prep column in the harness.

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Compared to the ml-inference case, we changed the table columns as follows:

  • added "Timing (server) - Model Prep"
  • removed "Timing (harness) - Input Gen"

I think it would be better to explain our intention. First, the reason we added "Model Prep" is that the encoding the model weights into plaintexts (taking about 20 mins) is an important unlike the other cases. And the encoding process must be performed on the server in our logic.

Second, I excluded one we considered less important from our perspective because one is added. Thus, there is no issue with adding "Input Gen" again.

Lastly, I am curious to know exactly which I/O you are referring to, because the I/O is included in every step.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The harness timing is what the harness is measuring, which might be inflated. But every line in the measurements file under "Timing": should have a corresponding column in the table under Timing (harness). So don't remove Input Gen as it currently appears in the measurements files.

For the server reported time, it makes sense to specify Model Prep as a column, but it has to be part of the server reported timing in the measurements files, otherwise it will not get populated.
About I/O, I was referring that in the current measurements from the BERT repository, this is what is being displayed in the Server reported times:
"Server Reported": {
"Encrypted computation": "347970.3173s",
"I/O": "16796.2555s",
"Total": "364766.573s"
}

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants