app: stacked_cores: enable 0.001-level precision for current setting
This commit is contained in:
@@ -156,6 +156,8 @@ _48xx_study = [(p, get_meas(p)) for p in
|
||||
SimParams48(5e2, 5e3, 1000, 50, 9, 1, 400, "1e10"),
|
||||
# # y0=0.60, slope0=0.96
|
||||
# SimParams48(5e2, 5e3, 1000, 50, 9, 1, 400, "2e10"),
|
||||
# y0=0.63, slope0=1.0 until x=0.15
|
||||
# SimParams48(1e3, 1e4, 2000, 100, 9, 1, 400, "2e10"),
|
||||
# y0=0.57, slope0=1.25 until x=0.30
|
||||
SimParams48(1e3, 1e4, 2000, 100, 9, 1, 400, "1e10"),
|
||||
# y0=0.47, slope0=1.1 until x=0.30
|
||||
|
@@ -28,15 +28,16 @@ def extract_one(path: str, t_first: float, t_last: float, t_mid: float = None):
|
||||
|
||||
def extract_polarity(stem: str) -> float:
|
||||
s = None
|
||||
if re.search("-p\d\d\d", stem):
|
||||
s = re.search("-p\d\d\d", stem).group(0)
|
||||
if re.search("-n\d\d\d", stem):
|
||||
s = re.search("-n\d\d\d", stem).group(0)
|
||||
if re.search("-p\d\d\d\d?", stem):
|
||||
s = re.search("-p\d\d\d\d?", stem).group(0)
|
||||
if re.search("-n\d\d\d\d?", stem):
|
||||
s = re.search("-n\d\d\d\d?", stem).group(0)
|
||||
|
||||
if s:
|
||||
sign = {'n': -1, 'p': 1}[s[1]]
|
||||
mag = int(s[2:])
|
||||
return sign * mag * 0.01
|
||||
max_mag = 10**(len(s[2:]) - 1)
|
||||
return sign * mag / max_mag
|
||||
|
||||
if "-000" in stem:
|
||||
return 0.00
|
||||
@@ -61,7 +62,7 @@ def extract_39xx(base_path: str, t_first: str = "2e-9", t_last: str = "3e-9", t_
|
||||
for i, (o, polarity, mid) in sorted(mappings.items()):
|
||||
comments = []
|
||||
if polarity is not None:
|
||||
comments += [f"{polarity:= 04.2f}"]
|
||||
comments += [f"{polarity:= 05.3f}"]
|
||||
for core, val in enumerate(mid):
|
||||
comments += [f"M{core+1}={val:5}"]
|
||||
|
||||
|
File diff suppressed because it is too large
Load Diff
Reference in New Issue
Block a user