Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
Bård Sørensen Hestmark
IDATT2900 45b
Commits
a95ceb16
Commit
a95ceb16
authored
May 08, 2022
by
Tommy Duc Luu
Browse files
comments
parent
b85de714
Changes
1
Hide whitespace changes
Inline
Side-by-side
interactive_CA/interactive.py
View file @
a95ceb16
...
...
@@ -64,9 +64,6 @@ class Interactive:
self
.
target_img
,
(
p
,
p
,
p
,
p
),
"constant"
,
0
)
self
.
pad_target
=
self
.
pad_target
.
repeat
(
1
,
1
,
1
,
1
)
# whidden = torch.concat((self.pad_target, torch.zeros((self.size,self.size,12))), axis=2)
# self.batch_target = tt(np.repeat(whidden[None, ...], 1, 0))
if
args
.
load_model_path
!=
""
:
self
.
load_model
(
args
.
load_model_path
)
...
...
@@ -151,10 +148,9 @@ class Interactive:
self
.
save_cell
(
x_eval
,
self
.
imgpath
)
cur_path
=
f
'
{
self
.
logdir
}
/
{
counter
}
.png'
# Damage at 51:
if
counter
in
[
40
,
60
,
100
,
150
,
200
,
400
]:
self
.
save_cell
(
x_eval
,
cur_path
)
# Quadratic erasing
# Quadratic erasing
at 51
# elif counter == 51:
# # record loss before dmg
# before_loss = self.net.loss(x_eval, self.pad_target)
...
...
Tommy Duc Luu
@tommydl
mentioned in commit
9bdd8c4c
·
Jun 21, 2022
mentioned in commit
9bdd8c4c
mentioned in commit 9bdd8c4c2061017862e9dec6325bf83c4bc1caf6
Toggle commit list
Write
Preview
Supports
Markdown
0%
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!
Cancel
Please
register
or
sign in
to comment