Skip to content

Commit

Permalink
Change np.math for math for compatibility
Browse files Browse the repository at this point in the history
Signed-off-by: Patrick Bloebaum <[email protected]>
  • Loading branch information
bloebp committed Oct 28, 2024
1 parent e79d012 commit 20fc848
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions dowhy/gcm/falsify.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
"""This module provides functionality to falsify a user-given DAG given observed data."""

import math
import warnings
from dataclasses import dataclass, field
from enum import Enum, auto
Expand Down Expand Up @@ -932,7 +932,7 @@ def __init__(self, causal_graph: DirectedGraph, exclude_original_order: bool, n_
self.causal_graph = causal_graph
self.exclude_original_order = exclude_original_order
self.n_permutations = n_permutations
self.max_perms = np.math.factorial(self.causal_graph.number_of_nodes()) - int(self.exclude_original_order)
self.max_perms = math.factorial(self.causal_graph.number_of_nodes()) - int(self.exclude_original_order)

if n_permutations == -1 or n_permutations > self.max_perms:
self.it = self.iter_all_permutations()
Expand Down

0 comments on commit 20fc848

Please sign in to comment.