FAQ
| This is a
LIVE
service |
Changelog
Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
S
solventmapcreator
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Iterations
Wiki
Requirements
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Test cases
Artifacts
Deploy
Releases
Package registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Code review analytics
Issue analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Yusuf Hamied Department of Chemistry
Hunter Group
SSIPtools
SSIMPLEapps
solventmapcreator
Commits
fc7baaac
Commit
fc7baaac
authored
7 years ago
by
M.D. Driver
Browse files
Options
Downloads
Patches
Plain Diff
continued working on functions.
parent
3f89efee
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
solventmapcreator/polynomialanalysis/polynomialdataanalysis.py
+27
-2
27 additions, 2 deletions
...ntmapcreator/polynomialanalysis/polynomialdataanalysis.py
with
27 additions
and
2 deletions
solventmapcreator/polynomialanalysis/polynomialdataanalysis.py
+
27
−
2
View file @
fc7baaac
...
...
@@ -16,7 +16,6 @@ LOGGER = logging.getLogger(__name__)
LOGGER
.
setLevel
(
logging
.
WARN
)
def
get_total_by_fit_order
(
best_order_dict
):
"""
This returns a tuple containing the order, and also the number of
occurances where the corresponding order provided the best fit.
...
...
@@ -24,7 +23,33 @@ def get_total_by_fit_order(best_order_dict):
order_tuple
=
tuple
(
sorted
(
best_order_dict
.
keys
()))
number_by_order
=
tuple
([
len
(
best_order_dict
[
order
])
for
order
in
order_tuple
])
return
(
order_tuple
,
number_by_order
)
def
extract_lists_by_order_of_alt_metric
(
solvent_id_list
,
solvent_ids_by_order
):
"""
This returns a dictionary where the solvent IDs are sorted based on the
best order from the alternate metric.
"""
solvent_id_alt_metric
=
{}
for
order
in
solvent_ids_by_order
.
keys
():
metric_ids_for_order
=
[]
for
solvent_id
in
solvent_id_list
:
if
solvent_id
in
solvent_ids_by_order
[
order
]:
metric_ids_for_order
.
append
(
solvent_id
)
solvent_id_alt_metric
[
order
]
=
metric_ids_for_order
return
solvent_id_alt_metric
def
get_solvent_id_by_order
(
best_order_dict
):
"""
This gets the values from the best order dict and returns lists of
solvent IDs group by the order of the polynomial that gives the best fit.
"""
solvent_ids_by_order
=
{}
for
order
in
best_order_dict
.
keys
():
solvent_ids_by_order
[
order
]
=
get_solvent_id
(
best_order_dict
[
order
])
return
solvent_ids_by_order
def
get_solvent_id
(
order_info_list
):
"""
This gets the values from the order info list about which solvents are in this set.
"""
return
[
order_info_list
[
i
][
0
]
for
i
in
range
(
len
(
order_info_list
))]
def
get_best_poly_fit_rmse
(
polynomial_dict_by_solvent_id
):
"""
This returns a dict with tuples containing the information.
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment