Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
Chetan Sharma
AMMP
Commits
3f029c7c
Commit
3f029c7c
authored
Jul 06, 2020
by
Chetan Sharma
Browse files
Small issue with db name
parent
655afdea
Changes
5
Hide whitespace changes
Inline
Side-by-side
software/ammp.py
View file @
3f029c7c
...
...
@@ -86,7 +86,7 @@ def ammp(MACHINE_PORT, SPINDLE_PORT, TFD_PORT, D, W, f_r, f_r_clearing, w, START
logging
.
info
(
"After bootstrap cut, model params are actually at: "
+
", "
.
join
([
"{:.5e}"
.
format
(
p
)
for
p
in
model
.
params
]))
if
USE_OLD_DATA
and
not
FAKE
:
with
shelve
.
open
(
os
.
path
.
join
(
"saved_cuts"
,
"
db
"
))
as
db
:
with
shelve
.
open
(
os
.
path
.
join
(
"saved_cuts"
,
"
shelve
"
))
as
db
:
model
.
ingest_data
(
db
[
USE_OLD_DATA
])
logging
.
info
(
"Partially optimized bootstrap cuts starting now"
)
...
...
software/collect_data.py
View file @
3f029c7c
...
...
@@ -6,7 +6,6 @@ import time
from
objects
import
EndMill
,
Conditions
,
MachineChar
from
cut
import
Cut
from
ml
import
LinearModel
from
optimize
import
Optimizer
import
logging
...
...
software/cut.py
View file @
3f029c7c
...
...
@@ -208,7 +208,7 @@ class Cut:
data
=
Data
(
self
.
D
,
W
,
f_r
,
w
,
self
.
endmill
,
Ts
,
Fys
)
if
self
.
save_as
and
save
:
with
shelve
.
open
(
os
.
path
.
join
(
"saved_cuts"
,
"
db
"
))
as
db
:
with
shelve
.
open
(
os
.
path
.
join
(
"saved_cuts"
,
"
shelve
"
))
as
db
:
if
self
.
save_as
in
db
:
existing
=
db
[
self
.
save_as
]
existing
.
append
(
data
)
...
...
software/data_observer.ipynb
View file @
3f029c7c
...
...
@@ -34831,4 +34831,4 @@
},
"nbformat": 4,
"nbformat_minor": 4
}
}
\ No newline at end of file
software/fake_cut.py
View file @
3f029c7c
...
...
@@ -69,7 +69,7 @@ class Fake_Cut:
class
ReplayCut
(
Fake_Cut
):
def
__init__
(
self
,
replay_data
,
model
,
T_func
,
F_func
,
error
,
noise
):
self
.
model
=
model
with
shelve
.
open
(
os
.
path
.
join
(
"saved_cuts"
,
"
db
"
))
as
db
:
with
shelve
.
open
(
os
.
path
.
join
(
"saved_cuts"
,
"
shelve
"
))
as
db
:
data
=
db
[
replay_data
]
self
.
model
.
ingest_data
(
data
)
super
().
__init__
(
self
.
model
.
params
,
T_func
,
F_func
,
error
,
noise
)
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment