The system cannot find the file specified
Can you verify if both `pydot` and `graphviz` are installed on your system and included in the system PATH for `subprocess` to execute?

```python
You must install pydot (`pip install pydot`) "
    454         "and install graphviz "
    455         "(see instructions at https://graphviz.gitlab.io/download/) "
    456         "for plot_model to work."
```

pip install pydot graphviz They are installed but I didn't set up a PATH. What do I put in path? installing from https://graphviz.gitlab.io/download/ made it work! Are you satisfied with the resolution of your issue?
<a href="https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=Yes&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/62760">Yes</a>
<a href="https://docs.google.com/forms/d/e/1FAIpQLSfaP12TRhd9xSxjXZjcZFNXPGk4kc1-qMdv3gc6bEP90vY1ew/viewform?entry.85265664=No&entry.2137816233=https://github.com/tensorflow/tensorflow/issues/62760">No</a>
 Great it helped 👍🏿 @ninjaguardian 
### Issue type

Support

### Have you reproduced the bug with TensorFlow Nightly?

No

### Source

source

### TensorFlow version

2.15.0

### Custom code

Yes

### OS platform and distribution

Windows 11

### Mobile device

_No response_

### Python version

3.11.7

### Bazel version

_No response_

### GCC/compiler version

_No response_

### CUDA/cuDNN version

_No response_

### GPU model and memory

_No response_

### Current behavior?

running: plot_model(model=model9,to_file='file.png',show_shapes=True, show_layer_names=True)

getting:
FileNotFoundError: [WinError 2] The system cannot find the file specified
AttributeError: module 'pydot' has no attribute 'InvocationException'

### Standalone code to reproduce the issue

```shell
import pydot
import graphviz
from tensorflow.keras.utils import plot_model

...make a model (the model isn't the problem. it works with other things fine)

plot_model(model=model9,to_file='file.png',show_shapes=True, show_layer_names=True)
```


### Relevant log output

```shell
FileNotFoundError                         Traceback (most recent call last)
File c:\Users\carte\AppData\Local\Programs\Python\Python311\Lib\site-packages\pydot\core.py:1753, in Dot.create(self, prog, format, encoding)
   1752 try:
-> 1753     stdout_data, stderr_data, process = call_graphviz(
   1754         program=prog,
   1755         arguments=arguments,
   1756         working_dir=tmp_dir,
   1757     )
   1758 except OSError as e:

File c:\Users\carte\AppData\Local\Programs\Python\Python311\Lib\site-packages\pydot\core.py:133, in call_graphviz(program, arguments, working_dir, **kwargs)
    131 program_with_args = [program] + arguments
--> 133 process = subprocess.Popen(
    134     program_with_args,
    135     env=env,
    136     cwd=working_dir,
    137     shell=False,
    138     stderr=subprocess.PIPE,
    139     stdout=subprocess.PIPE,
    140     **kwargs,
    141 )
    142 stdout_data, stderr_data = process.communicate()

File c:\Users\carte\AppData\Local\Programs\Python\Python311\Lib\subprocess.py:1026, in Popen.__init__(self, args, bufsize, executable, stdin, stdout, stderr, preexec_fn, close_fds, shell, cwd, env, universal_newlines, startupinfo, creationflags, restore_signals, start_new_session, pass_fds, user, group, extra_groups, encoding, errors, text, umask, pipesize, process_group)
   1023             self.stderr = io.TextIOWrapper(self.stderr,
   1024                     encoding=encoding, errors=errors)
-> 1026     self._execute_child(args, executable, preexec_fn, close_fds,
   1027                         pass_fds, cwd, env,
   1028                         startupinfo, creationflags, shell,
   1029                         p2cread, p2cwrite,
   1030                         c2pread, c2pwrite,
   1031                         errread, errwrite,
   1032                         restore_signals,
   1033                         gid, gids, uid, umask,
   1034                         start_new_session, process_group)
   1035 except:
   1036     # Cleanup if the child failed starting.

File c:\Users\carte\AppData\Local\Programs\Python\Python311\Lib\subprocess.py:1538, in Popen._execute_child(self, args, executable, preexec_fn, close_fds, pass_fds, cwd, env, startupinfo, creationflags, shell, p2cread, p2cwrite, c2pread, c2pwrite, errread, errwrite, unused_restore_signals, unused_gid, unused_gids, unused_uid, unused_umask, unused_start_new_session, unused_process_group)
   1537 try:
-> 1538     hp, ht, pid, tid = _winapi.CreateProcess(executable, args,
   1539                              # no special security
   1540                              None, None,
   1541                              int(not close_fds),
   1542                              creationflags,
   1543                              env,
   1544                              cwd,
   1545                              startupinfo)
   1546 finally:
   1547     # Child is launched. Close the parent's copy of those pipe
   1548     # handles that only the child should have open.  You need
   (...)
   1551     # pipe will not close when the child process exits and the
   1552     # ReadFile will hang.

FileNotFoundError: [WinError 2] The system cannot find the file specified

During handling of the above exception, another exception occurred:

FileNotFoundError                         Traceback (most recent call last)
File c:\Users\carte\AppData\Local\Programs\Python\Python311\Lib\site-packages\keras\src\utils\vis_utils.py:57, in check_graphviz()
     54 try:
     55     # Attempt to create an image of a blank graph
     56     # to check the pydot/graphviz installation.
---> 57     pydot.Dot.create(pydot.Dot())
     58     return True

File c:\Users\carte\AppData\Local\Programs\Python\Python311\Lib\site-packages\pydot\core.py:1762, in Dot.create(self, prog, format, encoding)
   1761     args[1] = '"{prog}" not found in path.'.format(prog=prog)
-> 1762     raise OSError(*args)
   1763 else:

FileNotFoundError: [WinError 2] "dot" not found in path.

During handling of the above exception, another exception occurred:

AttributeError                            Traceback (most recent call last)
Cell In[22], line 203
    201     elif DotOrPng.lower() == 'png':
    202         print("graphing")
--> 203         print(plot_model(model=model9,show_shapes=True, show_layer_names=True))
    204     print("graphed")
    205 if command.lower() == 'exit':

File c:\Users\carte\AppData\Local\Programs\Python\Python311\Lib\site-packages\keras\src\utils\vis_utils.py:451, in plot_model(model, to_file, show_shapes, show_dtype, show_layer_names, rankdir, expand_nested, dpi, layer_range, show_layer_activations, show_trainable)
    444 if not model.built:
    445     raise ValueError(
    446         "This model has not yet been built. "
    447         "Build the model first by calling `build()` or by calling "
    448         "the model on a batch of data."
    449     )
--> 451 if not check_graphviz():
    452     message = (
    453         "You must install pydot (`pip install pydot`) "
    454         "and install graphviz "
    455         "(see instructions at https://graphviz.gitlab.io/download/) "
    456         "for plot_model to work."
    457     )
    458     if "IPython.core.magics.namespace" in sys.modules:
    459         # We don't raise an exception here in order to avoid crashing
    460         # notebook tests where graphviz is not available.

File c:\Users\carte\AppData\Local\Programs\Python\Python311\Lib\site-packages\keras\src\utils\vis_utils.py:59, in check_graphviz()
     57     pydot.Dot.create(pydot.Dot())
     58     return True
---> 59 except (OSError, pydot.InvocationException):
     60     return False

AttributeError: module 'pydot' has no attribute 'InvocationException'
```
