Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
CHILD INTELLIGENT ASSESSMENT TOOL
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
2020-046
CHILD INTELLIGENT ASSESSMENT TOOL
Commits
b0fb949d
Commit
b0fb949d
authored
Jul 03, 2020
by
Gunasinghe M.D.
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Upload New File
parent
4937e59d
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
29 additions
and
0 deletions
+29
-0
visulization.py
visulization.py
+29
-0
No files found.
visulization.py
0 → 100644
View file @
b0fb949d
import
matplotlib.pyplot
as
plt
import
numpy
as
np
def
plot_model_history
(
model_history
):
fig
,
axs
=
plt
.
subplots
(
1
,
2
,
figsize
=
(
15
,
5
))
# summarize history for accuracy
axs
[
0
]
.
plot
(
range
(
1
,
len
(
model_history
.
history
[
'acc'
])
+
1
),
model_history
.
history
[
'acc'
])
axs
[
0
]
.
plot
(
range
(
1
,
len
(
model_history
.
history
[
'val_acc'
])
+
1
),
model_history
.
history
[
'val_acc'
])
axs
[
0
]
.
set_title
(
'Model Accuracy'
)
axs
[
0
]
.
set_ylabel
(
'Accuracy'
)
axs
[
0
]
.
set_xlabel
(
'Epoch'
)
axs
[
0
]
.
set_xticks
(
np
.
arange
(
1
,
len
(
model_history
.
history
[
'acc'
])
+
1
),
len
(
model_history
.
history
[
'acc'
])
/
10
)
axs
[
0
]
.
legend
([
'train'
,
'val'
],
loc
=
'best'
)
# summarize history for loss
axs
[
1
]
.
plot
(
range
(
1
,
len
(
model_history
.
history
[
'loss'
])
+
1
),
model_history
.
history
[
'loss'
])
axs
[
1
]
.
plot
(
range
(
1
,
len
(
model_history
.
history
[
'val_loss'
])
+
1
),
model_history
.
history
[
'val_loss'
])
axs
[
1
]
.
set_title
(
'Model Loss'
)
axs
[
1
]
.
set_ylabel
(
'Loss'
)
axs
[
1
]
.
set_xlabel
(
'Epoch'
)
axs
[
1
]
.
set_xticks
(
np
.
arange
(
1
,
len
(
model_history
.
history
[
'loss'
])
+
1
),
len
(
model_history
.
history
[
'loss'
])
/
10
)
axs
[
1
]
.
legend
([
'train'
,
'val'
],
loc
=
'best'
)
plt
.
show
()
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