add ONNX support for BLOOM
Author: nmntz
Pull request: yes

# What does this PR do?

add ONNX support for BLOOM

## Before submitting
- [ ] This PR fixes a typo or improves the docs (you can dismiss the other checks if that's the case).
- [X] Did you read the [contributor guideline](https://github.com/huggingface/transformers/blob/main/CONTRIBUTING.md#start-contributing-pull-requests),
      Pull Request section?
- [ ] Was this discussed/approved via a Github issue or the [forum](https://discuss.huggingface.co/)? Please add a link
      to it if that's the case.
- [X] Did you make sure to update the documentation with your changes? Here are the
      [documentation guidelines](https://github.com/huggingface/transformers/tree/main/docs), and
      [here are tips on formatting docstrings](https://github.com/huggingface/transformers/tree/main/docs#writing-source-documentation).
- [X] Did you write any new necessary tests?


## Who can review?

@michaelbenayoun 

<!-- Your PR will be replied to more quickly if you can figure out the right person to tag with @

 If you know how to use git blame, that is the easiest way, otherwise, here is a rough guide of **who to tag**.
 Please tag fewer than 3 people.

Models:

- albert, bert, xlm: @LysandreJik
- blenderbot, bart, marian, pegasus, encoderdecoder,  t5: @patrickvonplaten, @patil-suraj
- longformer, reformer, transfoxl, xlnet: @patrickvonplaten
- fsmt: @stas00
- funnel: @sgugger
- gpt2: @patrickvonplaten, @LysandreJik
- rag: @patrickvonplaten, @lhoestq
- tensorflow: @LysandreJik

Library:

- benchmarks: @patrickvonplaten
- deepspeed: @stas00
- ray/raytune: @richardliaw, @amogkam
- text generation: @patrickvonplaten
- tokenizers: @n1t0, @LysandreJik
- trainer: @sgugger
- pipelines: @LysandreJik

Documentation: @sgugger

HF projects:

- datasets: [different repo](https://github.com/huggingface/datasets)
- rust tokenizers: [different repo](https://github.com/huggingface/tokenizers)

Examples:

- maintained examples (not research project or legacy): @sgugger, @patil-suraj
- research_projects/bert-loses-patience: @JetRunner
- research_projects/distillation: @VictorSanh

 -->


Comments:
_The documentation is not available anymore as the PR was closed or merged._

As you told me offline that the slow tests were passing (under torch1.11.0), looks good to me! Thanks for working on that 🔥 

I'm not too sure about the changes in `modeling_bloom.py`. Looks like not leveraging the bool type and converting to int32 will hurt performance. Wdyt @younesbelkada ?

I think the changes in `modeling_bloom.py` come from the fact that boolean tensors cannot be added in ONNX (not 100% sure). Two suggestions then:

- Reformulate the addition to [torch.logical_or](https://pytorch.org/docs/stable/generated/torch.logical_or.html#torch-logical-or)
- Cast the input to int8

I think that the first solution is both faster and more aligned with the original implementation.
WDYT?

@sgugger I do not think this will hurt performances in terms of logits since slow tests are passing, but might hurt indeed the inference time performance for large and/or batched sequences.. We need to benchmark that though to be sure

@michaelbenayoun I think option 1 sounds good, yes!

Also make sure all the tests pass before merging.

All tests for `tests/onnx/test_onnx_v2.py -k "bloom"` and `tests/models/bloom` are passing.
Here are the ones that are skipped (which is fine according to @younesbelkada)
```
================================================================================= short test summary info =================================================================================
SKIPPED [1] tests/test_modeling_common.py:2006: test is PT+FLAX test
SKIPPED [1] tests/test_modeling_common.py:1934: test is PT+FLAX test
SKIPPED [1] tests/test_modeling_common.py:1758: test is PT+TF test
SKIPPED [1] tests/test_tokenization_common.py:1960: This test is only for slow tokenizers
SKIPPED [1] tests/test_tokenization_common.py:2189: test is PT+TF test
================================================================= 159 passed, 5 skipped, 35 warnings in 449.50s (0:07:29)
```

There is a difference between a copy in BLOOM and the original in GPT-2 which is why the CI is failing. Make sure to run `make fic-copies` or remove the `Copied from`.