►
From YouTube: SimPEG meeting May 23
Description
We discuss the use of the Properties library for making SimPEG objects serializable and having validation on properties and classes.
B
A
A
A
A
B
A
F
E
So
all
right,
you
guys
want
to
start
by
just
like
a
quick
overview
of
the
presentation
for
people
who
weren't
there
any
questions
that
are
conversations
that
you
guys
had
afterwards
to
ordered,
particularly
memorable
or
anything
like
that.
E
A
A
Yeah,
why
you
know
that
yeah
yeah
I
thought
they
they
appreciate
it
and
then
now
they
thought
like
they
could
use,
think
that
could
be
useful
with
their
design.
Their
survey
yeah
well
I'm,
not
100%,
sure
they're
going
to
use
it
because
I
get
they
may
not
even
use
any
for
Molly
cook
under
design
the
survey
it's
like
they
use
their
experience
Lee,
but
why
there's
some
tricky
part?
They
paint
it.
So
I
thought
that's
a
good
one.
Yeah
I
got.
C
B
G
G
E
E
He's
interested
in
like
understanding
the
fields
do
too
and
like
an
ellipsoidal
inclusion
or
like
an
ellipsoid
in
a
full
space,
just
subject
to
a
like
uniform
magnetic
field
right.
G
A
That's
fear,
yeah,
so
I
think
that's
his
name
interest
yeah,
probably
like
using
exactly
the
same
setup
and
then
just
change
the
model
yeah
Devin
like
if
you
can
send
it
to
end
Oh,
to
change
the
reach
sure
to
flip
story
yeah
and
see
all
of
that
time.
Changers
I
think
that
should
be
enough
to
start
yeah.
It
uses
a
loop.
C
E
E
C
G
C
E
A
A
strong
memory
system
and
what
you
definitely
but,
if
they're,
asking
CGI
to
the
inversion
yeah,
they
still
want
to
understand
when
they're
developing
your
system
yeah.
So
at
that
point
like
they
don't
care
what
the
versions
are
yourself,
what
they
want
to
sit
away
and
see
what's
happening
and
that
ability
is
all
ability
or
something
like
that
yeah.
So.
E
E
Okay,
so
what
I
wanted
to
go
over
today
was
looking
at
perhaps
a
bit
of
how
do
we
want
to
actually
streamline
setting
up
simulations
and
inversions
sort
of
like
driving,
sim,
potentially
so
I
know
we
all
sort
of
have
our
own
approach
right
now
to
generating
drivers
and
working
with
something.
It
would
be
nice
to
try
and
like
be
a
little
more
consistent
and
also
streamline
our
own
processes,
them
and
I.
E
E
Yeah
so
going
through
serializing
things
and
then
also
streamlining
how
we
need
like
set
up
and
write
scripts
out,
because
I
know,
like
often
you
want
to
set
it
up
notebook
or
something
like
that,
and
then
kick
it
over.
The
cluster
and
doing
that
in
a
notebook
is,
is
like
not
the
easiest.
So
I'll
show
you
a
bit
of
how
I
am
working
with
this
and
we
can
sort
of
freeform,
as
you
guys
have
questions
so
I'm
just
going
to
share
my
screen.
E
Okay,
so
first
off,
there's
two
repositories:
I'm
going
to
be
showing
you,
so
these
are
both
on
github,
it's
under
my
name
right
now,
so
there's
L
Hagee
base
casing
simulations,
and
this
is
just
all
the
the
Python
code.
E
E
Okay,
I'm
not
going
to
run
this
because
you
a
couple
things
that
I've
updated,
but
that's
okay,
so
the
first
thing
I
do
is
define
just
a
directory
of
where
stuff
is
going
to
be,
and
this
is
a
round
to
anything
that
I'm
going
to
create
so
that
it
knows
where
its
own
directory
is.
So
if
we
actually
look
at
the
code,
I'm
actually
just
going
to
pull
this.
E
So
here
one
of
the
first
things
I
do
is
set
up
a
like
a
casing.
Parameters
object,
so
this
I
recently
updated
just
a
little
bit,
so
it's
a
little
more
modular.
So
what
I
have
is
a
set
of
simulation
parameters,
and
from
this
like
this,
to
sort
of
the
first
thing,
I
set
up
that
just
is
geometry
and
then
maybe
a
couple
parameters
about
the
simulation
itself,
so
frequencies
and
times
because
from
there
you
then
make
all
the
decisions
about
how
to
design
your
mesh.
E
But
the
first
thing
is
is
just
like:
what's
my
model,
so
in
this
case,
I've
got
a
little
survey
parameters
class
its
frequency
time,
so
you
don't
actually
have
to
specify
both
these
rights.
It
could
be
frequency
or
time
or
DC,
and
then
I,
but
in
these
cases
I'm
only
working
with
grounded
sources,
so
I
have
both
the
source,
a
data
source
and
then,
like
my
my
simplest
class
here,
is
I've
got
a
whole
space
is
going
to
be
my
model.
It
has
a
file
name.
E
It
also
it
from
base
casing
and
inherits
a
directory.
So
when
I
set,
this
up
I
actually
set
a
directory
without
so
it
knows
it's
directory,
and
it's
so
safe
is
enough,
and
then
the
whole
space
is
simple.
You
know,
we've
got
a
SEMA
back
and
a
new
relative
back
background
from
there.
We
can
define
like
a
couple
just
handy
things
like
skin
depth
and
diffusion
distance,
and
then
here
I
also
know
it
knows
how
to
put
itself
onto
a
mesh.
E
D
E
E
E
Okay,
so
that
created
a
listening
that
guy.
So
this
is
my
powerful
trace
fish.
So
then,
if
I
do
hold
space
dot
serialize,
these
are
the
things
that
it's
going
to
save
about
itself.
So
it
knows
its
class,
it
knows
its
directory,
it's
file,
name
background
values,
the
source
locations,
and
it
also
knows
the
version
of
the
code,
which
is
handy
because
if
you
save
this
and
then
I
upgrade
that
like
is
non
backwards
compatible
because
know,
what's
happens
so
then
I
can
always
be
like.
E
Oh
yeah,
I'll
just
revert
to
this
version
of
my
code
and
I
can
rerun
this
or
you
can
like
realize
how
you
need
to
upgrade
it
so
in
this
cage
that
I
can
do
is
in
do
whole
space
dot
save
all
right.
So
it's
saved
that
guy.
So
then,
if
I
go
to
my
files
and
my
look
at
my
casing-
notebooks
there's
now
this
folder
called
example
to
the
show
yes,
and
so
all
it
is,
is
just
JSON
Oh.
E
Okay:
okay,
one
other
thing:
I
want
to
show
you
with
that
is
in
how
you
can
load
it
back
and
I
just
need
to
recall
my
name's
on
this.
E
So
I
hold
that
guy
model
parameters,
that's
the
default
name
all
right,
and
so
what
this
guy
then
does
is
I
just
wrote
a
little
function
that
can
actually
go
in
and
give
in
that
file,
because
it
knows
its
class
I
will
just
load
it
up
and
repopulate.
So
then,
in
this
case
a
whole
space,
oh
yeah,
so
with
that
it
can
do
something
like.
E
H
E
Can
show
you
the
code
for
that
if
you
want
so
in
this
case,
I
called
that
guy
CP,
which
is
a
silly
name,
but
that's
when
I
started
thinking
about
casing
parameters.
That's
what
is
shortened
through
my
head,
so
now
that
guy
I've
loaded
it
back
up
and
I
have
my
same
class
again.
So
if
I
ask
it
for
this
Sigma
back
I
have
my
Sigma
back.
So
then
that's
a
very
easy
way
to
like
build
this
guy
up.
E
You
can
visualize
it
save
it,
and
then
you
just
have
one
command
that
says
load
this
guy
up.
We
are
going
to
start
rerunning
simulations,
so
the
code
that
actually
loads
that
out
is
here,
and
so
it's
pretty
simple
and
Franklin
I'm
sure
you
have
some
ideas
on
this
and
I
would
love
to
through
them.
So
we
opened
up
the
JSON.
E
E
E
Okay,
so
what
with
all
the
vacating
stuff
there's
some
sort
of
odd
meshes
that
I
create,
because
we
want
to
really
finally
district
ties
right
around
the
well
and
then
like
pad
out
smoothly
to
sort
of
annex
region
where
you
actually
on
collect
data
and
then
pad
from
there.
So
I
don't
want
to
coat
that
up
every
time,
so
I've
sort
of
written
a
little
wrapper
that
basically
takes
you
know
reasonable
extent
and
goes
from
there
and
so
I
called
those
guys
mesh
generators.
E
And
so
here
in
this
case,
if
we
look
at
my
base
mesh
generator,
it
has
a
final
name.
It
also
it
takes
the
casing,
properties
or
casing
parameters.
Instance,
okay,
to
build
itself,
because
it's
going
to
ask
it's
going
to
ask
questions
about
the
geometry
of
the
casing.
One
thing
I'm
just
going
to
do
just
so.
This
generates
probably
a
better
mesh,
because
I'm
not
sure
how
to
work
for
the
whole
space
is,
let's
actually
just
do
a
casing
and
a
half
space.
E
E
D
E
E
It's
a
casing,
mesh
generator,
so
I
got
a
few
different
ones
and
there's
in
some
cases
I
just
want
like
a
simple
so
much
and
then
other
cases
you
want
this
like
funky
casing
one
and
not
needs
a
few
more
parameters
like
those
domain.
Next
to
it
whatever,
so
we
just
created
a
cheating
match,
so
I
can
do.
E
What
guy-
and
so
this
is
a
2d
mesh
and
then
here,
let's
just
generate
a
3d
to
also
compare.
E
So
I've
got
a
match
that
looks
kind
of
like
that.
So
I'll
show
you
what's
on
this
mesh
generator
for
the
3d
one.
E
Okay,
so
there's
a
few
more
things,
and
this
is
something
I'm
thinking
a
little
bit
about
too
is
I,
don't
actually
know
if
we
want
to
save
this
on
here,
not
yeah,
but
we
right
now
because
the
casing
parameters
are
defined
on
there
and
serialized
with
it,
and
then
it
also
has
its
sort
of
2/4
cell
sizes.
So
to
find
these
two
core
regions,
a
cell
size
in
the
Z
direction.
I
knows
it's
directory,
so
in
this
case
I
didn't
set
the
directory,
so
the
default
is
the
current
location.
I
E
So,
in
this
case,
I
defined
my
hy
as
a
little
stretched
match.
Essentially,
oh
so
because,
with
the
examples
I'm
doing
I'm
running
a
wire
out
along
this
direction,
so
that's
actually
the
only
workplace
I
really
need
to
discretize.
Okay,
fine,
so
yeah,
that's
nice,
but
if
I
put
in
like
the
number
4,
it
will
uniformly
discretize
it
just
like
sort
of
when
you're
working
with
the
typical
tensor
mention
cool.
Ok,
so
that
gives
us
a
mesh.
E
So
now
the
next
thing
we
can
do
with
that
is
now
that
we
have
a
mesh
and
we
have
parameters.
We
can
then
piece
together
like
physical
properties
on
the
mesh.
E
So
what
I've
done
with
that
is
to
find
a
very
simple
physical
properties
class,
so
I'm
just
going
to
scroll
down
and
we'll
go
there,
and
so
the
distinction
here-
and
this
is
something
that
I
would
appreciate
opinions
on
is
so
the
physical
properties
now
only
exist
once
you've
defined
a
mesh
and
you
define
your
casing
parameters,
so
you
have
to
define
both
to
like
have
meaningful
physical
properties.
I,
don't
know
if
it
needs
to
be
its
own
class,
but
it's
kind
of
nice.
E
So
what
I
do
here
is
I,
give
it
my
mesh
generator
and
my
model
parameters,
and
then
it
goes
in
and
based
on.
You
know
the
the
model
parameters
have
the
method
Sigma,
given
a
mesh
so
now
it'll
define
those
guys
as
vectors
and
as
properties
you
can
also
go
in
and
like
define,
wires
and
maps
and
stuff
like
that.
So
this
is
I.
Guess
like
a
step
closer
to
thinking
about
the
inversion
and
then
because
you
now
also
have
the
model
and
the
mesh.
You
can
go
ahead
and
plot
things.
E
A
E
In
that
case,
what
I
then
do
is
I've
got
this
guy
called
run.
So
here
what
I
do
is
I'll
set
up
a
casing,
so
I'll
close,
my
simulation
is
now
a
casing:
simulations
dot,
I'll
shake
code
after
first,
so
there's
a
base
simulation
in
this
case
it
has
a
field
filing
so
because
in
like
all
the
examples
I
want
to
run,
I
actually
saf
it
yields
so
I
get
that
just
a
name.
It
again
has
its
own
file
name.
So
it's
got
simulation
like
if
the
simulation
parameters
should
serialize.
E
It
now
takes
a
casing
parameters
guide
and
a
mesh
generator.
These
ones
I've
created
a
property
called
of
loadable
instance.
So
in
this
case,
I
can
give
it
a
file
name
and
I
will
just
go
and
load
it.
So
I
can
show
you
that.
H
E
Right
above
that,
so
that
guy
is
wrong
base,
so
here
all
it
does
is
it
is
either
an
instance.
It
is
either
like
an
instance.
Sorry
that
got
screwed
out
these,
so
it's
either
just
in
instance,
or
it
actually
is
a
file
name
that
I
can
then
go
and
load,
and
so
why
that's
handy
is
when
I
just
create
like
one
of
these
simulation
files,
I
condition,
seed
file
names.
Then
it
goes
and
recreates
everything.
E
E
E
E
B
E
So
I
know
like
where
my
little
wire
path
is:
okay,
yeah,
okay,
so
now
I've
got
a
source,
we've
got
a
model
and
we
know-
and
we
have
a
mesh
so
now
we
have
everything
we
need
to
go
in
and
create
a
casing
simulation,
so
the
assimilation
is
now
using
solutions
got
run,
run,
let's
do
DC,
because
that
is
faster.
E
So
I
would
give
you
my
simulation
DC.
So
in
addition
that
what
the
simulation
DC
actually
has
eyes,
it
has
a
source,
a
at
source
B.
So
this
one's
a
little
different
because
it
doesn't
actually
take
like
the
top
pacing
source.
It
doesn't
need
to
compute
the
wire
path
and
all
that
sort
of
stuff
all
it
needs
is
just
two
end
points.
E
What
else
it
also
knows
the
formulation,
the
problem
that
we're
working
on,
so
if
you
want
to
go
in
and
tinker
with
that,
you
can
and
then
here
I've
overwritten
the
default
to
call
it
fields
DC,
because
often
it's
been
brought
up
with
something
else,
so
I
don't
want
to
overwrite
it.
E
So
here
I
will
set
that
guy
up
so
I've
now
got
my
kitchen.
Routers
is
kitchen
model.
My
mesh
generator
is
Russian
3d.
My
it
also
inherits
the
directory
again.
E
E
So
you
can
see
that
all
kind
of
here
it
is-
we've
got
the
it's,
it's
self-doubt
problem,
sellout
source
survey
and
then
it
cared
so
I
can
actually
go
in
and
do
similar
to
not
validate
before
I
actually
go
and
on
everything.
What
that's
going
to
do
is
this
going
to
check
that
my
casing
parameters
are
all
set,
my
mesh
is
all
set,
my
source
is
set,
and
that,
like
everything
on
my
simulation,
makes
sense.
E
E
A
E
H
E
F
Then
those
those
get
called
when
you
call
validate
as
well.
F
F
F
Yeah,
so
so
what
that
method
actually
does
is
it
calls
all
the
registered
class
validators?
So
you
don't
really
have
to
extend
that
guy.
You
just
wrap
something
else
in
the
at
properties.
Validate
I,
don't
know,
I
can
I'm.
Looking
at
the
docs
now
to
see
there
isn't
a
great
example,
but
I
can
you
throw
together
something
that.
F
F
F
E
F
E
J
E
So
now,
I
have
there's
a
few
methods
here
that
are
pretty
handy,
so
I
have
right
pi,
which
is
actually
going
to
write
a
break
on
function
of
itself
and
then
I
also
have
run,
which
knows
how
to
go
ahead
and
run
itself.
So
all
that
right,
pi
does.
Is
this
C
it's
going
to
save
each
of
these
guys
and
because
they
all
know
their
own
names,
they
all
know
where
they
are.
We
can
write
that
out
like
in
a
very
declarative
way.
So
if
I
do.
E
K
J
Skin
is
actually
on
the
bottom
yeah.
What
was
SRC
there
like
this
Kevin,
wait
I'm
sure
to
find
it,
but
it
seems
like
your
times
that
was
your
time.
Steps
right.
E
K
E
So
that
shouldn't
potentially
work
cool
okay,
so
now
we
have
a
3d
time
to
am
sanitation,
so
if
I
do
double
check
it
cool.
So
now,
if
I
write
my
Python
file,
so
it's
saved
for
different
things.
So
it's
saved
example,
my
parameters,
JSON
model
parameters,
my
source
and
my
simulation
dot
pi.
So
what
simulation
dot
pi
looks
like.
E
This
so
in
this
case,
I
wrote
a
couple
things
that,
like
are
just
handy
for
me,
because
the
2d
simulation
is
dirt
cheap
and
in
the
DC
simulation
is
dirt
cheap,
so
I
just
assumed
that
any
time
I'm
going
to
run
something
in
3d
I
also
want
those,
and
you
can
set
those
as
parameters
like
in
the
right
function.
If
you
want
it,
yes
or
no,
so
let's
have
a
look
at
this.
This
is
actually.
This
is
all
that's
really
needed
for
the
the
main
simulation
the
rest
is
now
actually
constructing.
E
E
D
E
And
then
what's
nice
is
is
like
to
load
everything
up
again.
This
is
all
you
need
right
is
I
can,
on
the
back
end
now,
when
I
want
to
look
at
my
results,
this
is
all
that
I.
Do
is
I,
create
this
thing
again
and
then
I
just
load
out
my
fields,
because
it's
just
I'm
hiring
right
and
that
really
populates.
C
E
C
E
C
E
E
I
think
so
so
the
way
I
would
then
think
to
piece
that
together
is
that
you
know
how,
like
a
way
to
build
up
your
regularization,
your
data
misfit
list
out
the
directives,
and
all
of
that
so
I,
guess
that,
where
I
see
this
moving,
a
bit
is
realizing
that,
like
the
way
I've
defined
sources
and
things
like
that,
that
that
actually
should
be
or
the
way
it,
especially
if
serialized,
the
mesh
that
should
be
baked
in
in
peg,
there's
no
reason
that
I
actually
need
like
a
mesh
generator
other
than
like
my
custom
pieces,
but
the
simpad
match
should
serialized
right
and
be
able
to
recreate
itself,
and
so
the
biggest
thing
in
being
able
to
do.
E
A
Yeah,
that's
great,
that's
great
and
it's
potentially
like
even
the
same
engine
could
be
used
for
different
different
applications
like
there's
like
vm
code,
either
multiple
allocation,
yeah,
even
the
see
a
thing,
so
you
can
kind
of
make
some
customized
simulations
version.
Yes,
yeah
yeah,
that's
nice!
I
really
want
to
play
with
that.
I
kinda
want
to
build
something
similar
to
seem
sure
sure,
yeah.
E
J
A
E
A
E
E
E
C
Better
and
I'm
also
thinking
when
you
were,
you
know,
let's
say
Craig
or
Jeff
yeah
yeah
scripts,
and
then
we
don't
change
it,
but
the
base
code
and
they
need
to
change
all
the
screws,
yeah
hope
and
change
of
our
walls
that
may
just
regenerate
for
them.
Yeah
yeah,
because
here
to
grow
and
change
via
the
base
coat
yeah.
G
G
E
A
A
C
F
F
E
Yes,
I
think
you
can
I've
played
around
with
JSON
and
JSON,
but
loads
and
stuff,
like
it
actually
right
now,
I'm
leveraging
the
properties
serialization,
so
I
just
dumped
it.
The
way
that,
because
it.
A
H
That's
great
and
it's.