Skip to content

Commit

Permalink
Lint
Browse files Browse the repository at this point in the history
- raw_input is deprecated in Python 3
- Properly import ones from numpy
  • Loading branch information
rajadain committed Dec 27, 2021
1 parent 6269254 commit c235e0e
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
2 changes: 1 addition & 1 deletion CreateVariableFiles.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import os


variable_name = raw_input("Enter the name of the variable:")
variable_name = input("Enter the name of the variable:")

#write variable file
var_filename = "%s.py"%(variable_name)
Expand Down
3 changes: 2 additions & 1 deletion gwlfe/DailyArrayConverter.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
import random

import numpy as np
import numpy.ma as ma
# from numba import jit
from numpy import array
Expand Down Expand Up @@ -63,7 +64,7 @@


def mask_builder(DaysMonth):
ones = ravel(ones((12, 31))).astype("int")
ones = ravel(np.ones((12, 31))).astype("int")
slices = []
for i, month in enumerate(DaysMonth[0]):
slices.append(slice(31 * i, 31 * i + month))
Expand Down

0 comments on commit c235e0e

Please sign in to comment.