Repository: pykale/pykale (language: python)

Issue:
Upgrade to support Numpy 2.0.0+ and Matplotlib 3.9.1+
### Description
Upgrade to support Numpy 2.0.0+ and Matplotlib 3.9.1+. This PR aims to fix bugs raised by Numpy 2.0.0, released on 16th June 2024.

1. Drop support for Python 3.8, as Numpy 2.0.0 supports Python 3.9-3.12.
2. Pin RDKit to version 2024.3.2 to accommodate Numpy 2.0.0. This constraint should be lifted once RDKit 2024.3.4 is released.

#### [Resolved] This PR is stuck due to the conflict between RDKit and Numpy. RDKit 2024.3.4 can support Numpy 2.0.0. This version has been released on [RDKit GitHub](https://github.com/rdkit/rdkit/releases) but is not ready in [RDKit-python PyPI](https://pypi.org/project/rdkit/#history). I will update this PR after [the formal update](https://github.com/kuelumbus/rdkit-pypi/pull/105) is released.

#### After this PR merges, we should update pip caches by removing those for Python 3.8 and storing the new versions of changed dependencies. 


### Status
**Work in progress**

### Types of changes
<!--- Put an `x` in all the boxes that apply, and remove the not applicable items -->
- [ ] Non-breaking change (fix or new feature that would not break existing functionality).
- [x] Breaking change (fix or new feature that would cause existing functionality to change).
- [ ] New tests added to cover the changes.
- [ ] In-line docstrings updated.
- [ ] [Source for documentation at `docs`](https://github.com/pykale/pykale/tree/main/docs/source) manually updated for new API. 



Discussion / hints:

Fix patch:
diff --git a/setup.py b/setup.py
index 4a9f22b19..d511dc6a2 100644
--- a/setup.py
+++ b/setup.py
@@ -15,7 +15,7 @@
 
 # Core dependencies frequently used in PyKale Core API
 install_requires = [
-    "numpy>=1.18.0",  # sure
+    "numpy<2.0.0",  # sure
     "pandas",  # sure
     "pytorch-lightning>=2.0.0",  # in pipeline API only
     "scikit-learn>=0.23.2",  # sure


Test patch:
diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml
index 9180d02f0..f645822f9 100644
--- a/.github/workflows/test.yml
+++ b/.github/workflows/test.yml
@@ -45,9 +45,9 @@ jobs:
         uses: actions/cache@v2
         with:
           path: ${{ matrix.path }}
-          key: ${{ runner.os }}-python${{ matrix.python-version }}-pip-20231130-${{ hashFiles('**/setup.py') }}
+          key: ${{ runner.os }}-python${{ matrix.python-version }}-pip-20240705-${{ hashFiles('**/setup.py') }}
           restore-keys: |
-            ${{ runner.os }}-python${{ matrix.python-version }}-pip-20231130-
+            ${{ runner.os }}-python${{ matrix.python-version }}-pip-20240705-
           # We have used a softer matching strategy for the full hash of setup.py, as recommended by GitHub.
           # See: https://github.com/davronaliyev/Cache-dependencies-in-GitHub-Actions/blob/main/examples.md#python---pip
           # This restores the cache first and then downloads any changed packages to avoid updating the cache with