Changeset 3e6829d in sasview for src/sas/sascalc/pr
- Timestamp:
- Oct 22, 2018 5:49:40 PM (6 years ago)
- Branches:
- master, magnetic_scatt, release-4.2.2, ticket-1009, ticket-1094-headless, ticket-1242-2d-resolution, ticket-1243, ticket-1249
- Children:
- 57e48ca
- Parents:
- 7ba6470
- Location:
- src/sas/sascalc/pr
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
src/sas/sascalc/pr/fit/BumpsFitting.py
r9a5097c r3e6829d 2 2 BumpsFitting module runs the bumps optimizer. 3 3 """ 4 from __future__ import division 5 4 6 import os 5 7 from datetime import timedelta, datetime … … 34 36 class Progress(object): 35 37 def __init__(self, history, max_step, pars, dof): 36 remaining_time = int(history.time[0]*( float(max_step)/history.step[0]-1))38 remaining_time = int(history.time[0]*(max_step/history.step[0]-1)) 37 39 # Depending on the time remaining, either display the expected 38 40 # time of completion, or the amount of time remaining. Use precision -
src/sas/sascalc/pr/invertor.py
r952ea1f r3e6829d 6 6 FIXME: The way the Invertor interacts with its C component should be cleaned up 7 7 """ 8 from __future__ import division 8 9 9 10 import numpy as np … … 496 497 try: 497 498 cov = np.linalg.pinv(inv_cov) 498 err = math.fabs(chi2 / float(npts - nfunc)) * cov499 err = math.fabs(chi2 / (npts - nfunc)) * cov 499 500 except Exception as exc: 500 501 # We were not able to estimate the errors -
src/sas/sascalc/pr/num_term.py
r2469df7 r3e6829d 1 from __future__ import print_function 1 from __future__ import print_function, division 2 2 3 3 import math … … 51 51 osc = self.sort_osc() 52 52 dv = len(osc) 53 med = float(dv) / 2.053 med = 0.5*dv 54 54 odd = self.is_odd(dv) 55 55 medi = 0 … … 140 140 nts = self.compare_err() 141 141 div = len(nts) 142 tem = float(div) / 2.0142 tem = 0.5*div 143 143 if self.is_odd(div): 144 144 nt = nts[int(tem)]
Note: See TracChangeset
for help on using the changeset viewer.