`utils/check_repo.py` errors out on main with `jax;numpy` dependency on `modeling_flax_albert`
Author: molbap
Pull request: no
Labels: name: bug

### System Info

- `transformers` version: 4.46.0.dev0
- Platform: Linux-6.8.0-45-generic-x86_64-with-glibc2.35
- Python version: 3.11.7
- Huggingface_hub version: 0.23.3
- Safetensors version: 0.4.5
- Accelerate version: 0.34.2
- Accelerate config: 	not found
- PyTorch version (GPU?): 2.4.1+cu121 (True)
- Tensorflow version (GPU?): 2.18.0-dev20240917 (True)
- Flax version (CPU?/GPU?/TPU?): not installed (NA)
- Jax version: not installed
- JaxLib version: not installed
- Using distributed or parallel set-up in script?: No
- Using GPU in script?: No
- GPU type: NVIDIA GeForce RTX 4060 Laptop GPU


### Who can help?

@ArthurZucker 

### Information

- [ ] The official example scripts
- [ ] My own modified scripts

### Tasks

- [ ] An officially supported task in the `examples` folder (such as GLUE/SQuAD, ...)
- [ ] My own task or dataset (give details below)

### Reproduction

As in title. 
1. `git clone git@github.com:huggingface/transformers.git`
2. `cd transformers`
3. `python utils/check_repo.py`

Will yield

```bash
Traceback (most recent call last):
  File "/home/pablo/git/transformers/src/transformers/utils/import_utils.py", line 1764, in _get_module
    return importlib.import_module("." + module_name, self.__name__)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/pablo/anaconda3/envs/work/lib/python3.11/importlib/__init__.py", line 126, in import_module
    return _bootstrap._gcd_import(name[level:], package, level)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "<frozen importlib._bootstrap>", line 1204, in _gcd_import
  File "<frozen importlib._bootstrap>", line 1176, in _find_and_load
  File "<frozen importlib._bootstrap>", line 1147, in _find_and_load_unlocked
  File "<frozen importlib._bootstrap>", line 690, in _load_unlocked
  File "<frozen importlib._bootstrap_external>", line 940, in exec_module
  File "<frozen importlib._bootstrap>", line 241, in _call_with_frames_removed
  File "/home/pablo/git/transformers/src/transformers/models/albert/modeling_flax_albert.py", line 18, in <module>
    import flax
  File "/home/pablo/anaconda3/envs/work/lib/python3.11/site-packages/flax/__init__.py", line 24, in <module>
    from flax import core
  File "/home/pablo/anaconda3/envs/work/lib/python3.11/site-packages/flax/core/__init__.py", line 15, in <module>
    from .axes_scan import broadcast as broadcast
  File "/home/pablo/anaconda3/envs/work/lib/python3.11/site-packages/flax/core/axes_scan.py", line 21, in <module>
    import jax.numpy as jnp
ModuleNotFoundError: No module named 'jax.numpy'

The above exception was the direct cause of the following exception:

Traceback (most recent call last):
  File "/home/pablo/git/transformers/utils/check_repo.py", line 1196, in <module>
    check_repo_quality()
  File "/home/pablo/git/transformers/utils/check_repo.py", line 1175, in check_repo_quality
    check_models_are_in_init()
  File "/home/pablo/git/transformers/utils/check_repo.py", line 501, in check_models_are_in_init
    for module in get_model_modules():
                  ^^^^^^^^^^^^^^^^^^^
  File "/home/pablo/git/transformers/utils/check_repo.py", line 447, in get_model_modules
    modeling_module = getattr(model_module, submodule)
                      ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/pablo/git/transformers/src/transformers/utils/import_utils.py", line 1739, in __getattr__
    value = self._get_module(name)
            ^^^^^^^^^^^^^^^^^^^^^^
  File "/home/pablo/git/transformers/src/transformers/utils/import_utils.py", line 1766, in _get_module
    raise RuntimeError(
RuntimeError: Failed to import transformers.models.albert.modeling_flax_albert because of the following error (look up to see its traceback):
No module named 'jax.numpy'

```

### Expected behavior

`check_repo` should run without errors. Seems to be caused by `albert` model init file. 

Comments:
Hmmm this should not error out, checking