Skip to content

Commit

Permalink
Use random subpackage from numpy (#26)
Browse files Browse the repository at this point in the history
  • Loading branch information
mdpiper committed Jun 24, 2022
1 parent 9b73df5 commit 1329f47
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions heat/heat.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

import numpy as np
import yaml
from scipy import ndimage, random
from scipy import ndimage


def solve_2d(temp, spacing, out=None, alpha=1.0, time_step=1.0):
Expand Down Expand Up @@ -104,7 +104,7 @@ def __init__(
self._alpha = alpha
self._time_step = min(spacing) ** 2 / (4.0 * self._alpha)

self._temperature = random.random(self._shape)
self._temperature = np.random.random(self._shape)
self._next_temperature = np.empty_like(self._temperature)

@property
Expand Down

0 comments on commit 1329f47

Please sign in to comment.