File tree Expand file tree Collapse file tree 1 file changed +9
-7
lines changed
Expand file tree Collapse file tree 1 file changed +9
-7
lines changed Original file line number Diff line number Diff line change 66License: https://creativecommons.org/licenses/by/4.0)
77"""
88
9- #TODO: check that we have at least version 3.6
10-
11- import inspect
12-
139import logging
1410logger = logging .getLogger (name = 'modsim.py' )
1511
12+ # make sure we have Python 3.6 or better
13+ import sys
14+ if sys .version_info < (3 , 6 ):
15+ logger .warn ('modsim.py depends on Python 3.6 features.' )
16+
17+ import inspect
1618import matplotlib .pyplot as plt
1719import numpy as np
1820import pandas as pd
21+ import scipy
22+ import sympy
1923
2024import seaborn as sns
2125sns .set (style = 'white' , font_scale = 1.5 )
2226
23- import scipy
24- import sympy
2527import pint
2628UNITS = pint .UnitRegistry ()
2729Quantity = UNITS .Quantity
2830
31+ # expose some names so we can use them without dot notation
2932from copy import copy
3033from numpy import sqrt , log , exp , pi
3134from pandas import DataFrame , Series
3740from scipy .optimize import minimize_scalar
3841
3942
40-
4143def linspace (start , stop , num = 50 , ** kwargs ):
4244 """Returns an array of evenly-spaced values in the interval [start, stop].
4345
You can’t perform that action at this time.
0 commit comments