asteroid_spinprops 1.2.3__tar.gz → 1.2.5__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {asteroid_spinprops-1.2.3 → asteroid_spinprops-1.2.5}/PKG-INFO +1 -1
- {asteroid_spinprops-1.2.3 → asteroid_spinprops-1.2.5}/asteroid_spinprops/ssolib/periodest.py +8 -7
- {asteroid_spinprops-1.2.3 → asteroid_spinprops-1.2.5}/pyproject.toml +1 -1
- {asteroid_spinprops-1.2.3 → asteroid_spinprops-1.2.5}/README.md +0 -0
- {asteroid_spinprops-1.2.3 → asteroid_spinprops-1.2.5}/asteroid_spinprops/__init__.py +0 -0
- {asteroid_spinprops-1.2.3 → asteroid_spinprops-1.2.5}/asteroid_spinprops/ssolib/__init__.py +0 -0
- {asteroid_spinprops-1.2.3 → asteroid_spinprops-1.2.5}/asteroid_spinprops/ssolib/dataprep.py +0 -0
- {asteroid_spinprops-1.2.3 → asteroid_spinprops-1.2.5}/asteroid_spinprops/ssolib/modelfit.py +0 -0
- {asteroid_spinprops-1.2.3 → asteroid_spinprops-1.2.5}/asteroid_spinprops/ssolib/ssptools.py +0 -0
- {asteroid_spinprops-1.2.3 → asteroid_spinprops-1.2.5}/asteroid_spinprops/ssolib/utils.py +0 -0
{asteroid_spinprops-1.2.3 → asteroid_spinprops-1.2.5}/asteroid_spinprops/ssolib/periodest.py
RENAMED
|
@@ -210,7 +210,8 @@ def get_multiterm_period_estimate(
|
|
|
210
210
|
|
|
211
211
|
rms = np.sqrt(np.mean(residuals**2))
|
|
212
212
|
n_params = 2 * k + 1 + 3 * len(bands)
|
|
213
|
-
dof =
|
|
213
|
+
dof = n_params
|
|
214
|
+
N = len(residuals)
|
|
214
215
|
|
|
215
216
|
results.append((k, f_best, rms, dof, n_params))
|
|
216
217
|
|
|
@@ -219,13 +220,13 @@ def get_multiterm_period_estimate(
|
|
|
219
220
|
for i in range(len(results) - 1):
|
|
220
221
|
k, f_best, rss, dof, n_params = results[i]
|
|
221
222
|
k_next, f_best_next, rss_next, dof_next, n_params_next = results[i + 1]
|
|
222
|
-
F = ((rss -
|
|
223
|
+
F = ((rss**2/rss_next**2) - 1) * ((N - dof_next) / (dof_next - dof))
|
|
223
224
|
|
|
224
225
|
# Here crit = Fstat value for which model_2 (more complex) is in fact better than model_1 (less complex)
|
|
225
226
|
crit = ftest.ppf(
|
|
226
227
|
q=0.99,
|
|
227
228
|
dfn=n_params_next - n_params,
|
|
228
|
-
dfd=
|
|
229
|
+
dfd=N - n_params_next,
|
|
229
230
|
)
|
|
230
231
|
|
|
231
232
|
model_comparison.loc[i, "k"] = k
|
|
@@ -233,7 +234,7 @@ def get_multiterm_period_estimate(
|
|
|
233
234
|
model_comparison.loc[i, "f_best"] = f_best
|
|
234
235
|
model_comparison.loc[i, "Fstat"] = F
|
|
235
236
|
model_comparison.loc[i, "alpha_crit"] = crit
|
|
236
|
-
model_comparison.loc[i, "rms"] =
|
|
237
|
+
model_comparison.loc[i, "rms"] = rss
|
|
237
238
|
|
|
238
239
|
cond = model_comparison["Fstat"] > model_comparison["alpha_crit"]
|
|
239
240
|
model_comparison = model_comparison[
|
|
@@ -241,11 +242,11 @@ def get_multiterm_period_estimate(
|
|
|
241
242
|
] # don't go for the more complex model
|
|
242
243
|
f_chosen = model_comparison[
|
|
243
244
|
model_comparison.k == model_comparison.k.min()
|
|
244
|
-
].f_best[0] # Simplest model
|
|
245
|
-
k_val = model_comparison[model_comparison.k == model_comparison.k.min()].k[
|
|
245
|
+
].f_best.values[0] # Simplest model
|
|
246
|
+
k_val = model_comparison[model_comparison.k == model_comparison.k.min()].k.values[
|
|
246
247
|
0
|
|
247
248
|
] # Simplest model
|
|
248
|
-
p_rms = model_comparison[model_comparison.k == model_comparison.k.min()].rms[
|
|
249
|
+
p_rms = model_comparison[model_comparison.k == model_comparison.k.min()].rms.values[
|
|
249
250
|
0
|
|
250
251
|
] # Simplest model
|
|
251
252
|
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
[project]
|
|
2
2
|
name = "asteroid_spinprops"
|
|
3
|
-
version = "1.2.
|
|
3
|
+
version = "1.2.5"
|
|
4
4
|
description = "Collection of tools used for fitting sHG1G2 and SOCCA photometric models to sparse asteroid photometry"
|
|
5
5
|
authors = [
|
|
6
6
|
{name = "Odysseas",email = "odysseas.xenos@proton.me"}
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|