You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on Dec 8, 2024. It is now read-only.
K = laplacian_kernel(training, training, sigma=100.0)
107
+
training = comps[:1000]
109
108
109
+
K = laplacian_kernel(training, training, sigma=100.0)
110
+
```
110
111
111
112
Example 1: Using ARAD representation
112
113
113
-
from qml.kernels import arad_kernel
114
+
```python
115
+
from qml.kernels import arad_kernel
114
116
115
-
comps = ...# load a Python list of Compunds
117
+
comps = ...# load a Python list of Compunds
116
118
117
-
for comp in comps:
118
-
comp.generate_coulomb_matrix()
119
+
for comp in comps:
120
+
comp.generate_coulomb_matrix()
119
121
120
-
training = comps[:1000]
122
+
training = comps[:1000]
121
123
122
-
K = arad_kernel(training, training, sigma=100.0)
124
+
K = arad_kernel(training, training, sigma=100.0)
125
+
```
123
126
124
127
Additionally forARAD, when the two sets of `Compound` are identical, it is possible to calculate only the upper triangle, which reduces the computational load by a factor of two.
125
128
126
-
from qml.kernels import arad_training_kernel
127
-
K = arad_training_kernel(training, sigma=100.0)
128
-
129
+
```python
130
+
from qml.kernels import arad_training_kernel
131
+
K = arad_training_kernel(training, sigma=100.0)
132
+
```
129
133
130
134
## 3.2) Calculate kernels using the `qml.kernels` module directly
0 commit comments