Replies: 2 comments 1 reply
-
Hi. Can you give me details of the system you are running it on - the interface, the system configuration etc? I see Number of devices = 2. Are you running it on 2 GPUs? |
Beta Was this translation helpful? Give feedback.
1 reply
-
We've had quite some updates, please open an issue if it still persists. |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
I was trying to use GPDCtorch to speed up the nonlinear causal discovery calculations. GPDCtorch can compute the results. However, to my surprise, it runs even slower than GPDC.
Here's my data generation process.
`import numpy as np
from matplotlib import pyplot as plt
T = 200
np.random.seed(1)
data = np.random.randn(T, 4)
for t in range(1, T):
data[t, 1] += 0.4data[t-2, 0]**2
data[t, 2] += 0.2data[t-4, 1]**2
data[t, 3] += 0.5data[t-3, 2]**2 - 0.6data[t-5, 1]
var_names=['A','B','C','D']
from tigramite import data_processing as pp
from tigramite import plotting as tp
from tigramite.pcmci import PCMCI
from tigramite.independence_tests import ParCorr, GPDC, CMIknn, CMIsymb, GPDCtorch
dataframe = pp.DataFrame(data, var_names=var_names)
tp.plot_timeseries(dataframe)
plt.show()`
Then I use GPDC for causal discovery.
`
gpdc = GPDC(significance='analytic', gp_params=None)
pcmci_gpdc = PCMCI(
dataframe=dataframe,
cond_ind_test=gpdc,
verbosity=0)
results = pcmci_gpdc.run_pcmci(tau_max=5, pc_alpha=0.1)
pcmci_gpdc.print_significant_links(
p_matrix = results['p_matrix'],
val_matrix = results['val_matrix'],
alpha_level = 0.01)
`
The calculation took 21.6 seconds.
Then I used GPDCtorch instead.
`
gpdctorch = GPDCtorch(significance='analytic')
pcmci_gpdc_torch = PCMCI(
dataframe=dataframe,
cond_ind_test=gpdctorch,
verbosity=0)
results = pcmci_gpdc_torch.run_pcmci(tau_max=5, pc_alpha=0.1)
pcmci_gpdc_torch.print_significant_links(
p_matrix = results['p_matrix'],
val_matrix = results['val_matrix'],
alpha_level = 0.01)
`
The calculation took 187.8s.
So I'm wondering what's wrong with my use of GPDCtorch?
Beta Was this translation helpful? Give feedback.
All reactions