Skip to content

Commit

Permalink
Merge pull request #62 from ubermag/correction
Browse files Browse the repository at this point in the history
corrections
  • Loading branch information
lang-m authored May 9, 2024
2 parents 3f67ff6 + 1a8efbf commit 4938524
Show file tree
Hide file tree
Showing 6 changed files with 30 additions and 60 deletions.
27 changes: 9 additions & 18 deletions micromagneticdata/abstract_drive.py
Original file line number Diff line number Diff line change
Expand Up @@ -60,8 +60,7 @@ def x(self):
>>> import os
>>> import micromagneticdata as md
...
>>> dirname = dirname=os.path.join(os.path.dirname(__file__),
... 'tests', 'test_sample')
>>> dirname = os.path.join(os.path.dirname(__file__), 'tests', 'test_sample')
>>> drive = md.Data(name='hysteresis', dirname=dirname)[0]
>>> drive.x
'B_hysteresis'
Expand Down Expand Up @@ -100,8 +99,7 @@ def m0(self):
>>> import os
>>> import micromagneticdata as md
...
>>> dirname = dirname=os.path.join(os.path.dirname(__file__),
... 'tests', 'test_sample')
>>> dirname = os.path.join(os.path.dirname(__file__), 'tests', 'test_sample')
>>> drive = md.Drive(name='system_name', number=0, dirname=dirname)
>>> drive.m0
Field(...)
Expand Down Expand Up @@ -136,8 +134,7 @@ def table(self):
>>> import os
>>> import micromagneticdata as md
...
>>> dirname = dirname=os.path.join(os.path.dirname(__file__),
... 'tests', 'test_sample')
>>> dirname = os.path.join(os.path.dirname(__file__), 'tests', 'test_sample')
>>> drive = md.Drive(name='system_name', number=0, dirname=dirname)
>>> drive.table # doctest: +SKIP
E...
Expand All @@ -163,8 +160,7 @@ def n(self):
>>> import os
>>> import micromagneticdata as md
...
>>> dirname = dirname=os.path.join(os.path.dirname(__file__),
... 'tests', 'test_sample')
>>> dirname = os.path.join(os.path.dirname(__file__), 'tests', 'test_sample')
>>> drive = md.Drive(name='system_name', number=0, dirname=dirname)
>>> drive.n
25
Expand Down Expand Up @@ -193,8 +189,7 @@ def __getitem__(self, item):
>>> import os
>>> import micromagneticdata as md
...
>>> dirname = dirname=os.path.join(os.path.dirname(__file__),
... 'tests', 'test_sample')
>>> dirname = os.path.join(os.path.dirname(__file__), 'tests', 'test_sample')
>>> drive = md.Drive(name='system_name', number=0, dirname=dirname)
>>> drive[5]
Field(...)
Expand Down Expand Up @@ -230,8 +225,7 @@ def __iter__(self):
>>> import os
>>> import micromagneticdata as md
...
>>> dirname = dirname=os.path.join(os.path.dirname(__file__),
... 'tests', 'test_sample')
>>> dirname = os.path.join(os.path.dirname(__file__), 'tests', 'test_sample')
>>> drive = md.Drive(name='system_name', number=0, dirname=dirname)
>>> list(drive)
[...]
Expand Down Expand Up @@ -284,8 +278,7 @@ def __lshift__(self, other):
>>> import os
>>> import micromagneticdata as md
...
>>> dirname = dirname=os.path.join(os.path.dirname(__file__),
... 'tests', 'test_sample')
>>> dirname = os.path.join(os.path.dirname(__file__), 'tests', 'test_sample')
>>> drive_0 = md.Drive(name='system_name', number=0, dirname=dirname)
>>> drive_1 = md.Drive(name='system_name', number=1, dirname=dirname)
>>> drive_0 << drive_1
Expand Down Expand Up @@ -338,8 +331,7 @@ def to_xarray(self, *args, **kwargs):
>>> import os
>>> import micromagneticdata as md
...
>>> dirname = dirname=os.path.join(os.path.dirname(__file__),
... 'tests', 'test_sample')
>>> dirname = os.path.join(os.path.dirname(__file__), 'tests', 'test_sample')
>>> drive = md.Drive(name='system_name', number=0, dirname=dirname)
>>> xr_drive = drive.to_xarray(name='Mag')
>>> xr_drive
Expand Down Expand Up @@ -416,8 +408,7 @@ def hv(self):
>>> import os
>>> import micromagneticdata as md
...
>>> dirname = dirname=os.path.join(os.path.dirname(__file__),
... 'tests', 'test_sample')
>>> dirname = os.path.join(os.path.dirname(__file__), 'tests', 'test_sample')
>>> drive = md.Drive(name='system_name', number=0, dirname=dirname)
>>> drive.hv(kdims=['x', 'y'])
:DynamicMap...
Expand Down
9 changes: 3 additions & 6 deletions micromagneticdata/combined_drive.py
Original file line number Diff line number Diff line change
Expand Up @@ -40,8 +40,7 @@ class CombinedDrive(md.AbstractDrive):
>>> import os
>>> import micromagneticdata as md
...
>>> dirname = dirname=os.path.join(os.path.dirname(__file__),
... 'tests', 'test_sample')
>>> dirname = os.path.join(os.path.dirname(__file__), 'tests', 'test_sample')
>>> drive = md.Drive(name='system_name', number=0, dirname=dirname)
"""
Expand Down Expand Up @@ -91,8 +90,7 @@ def __repr__(self):
>>> import os
>>> import micromagneticdata as md
...
>>> dirname = dirname=os.path.join(os.path.dirname(__file__),
... 'tests', 'test_sample')
>>> dirname = os.path.join(os.path.dirname(__file__), 'tests', 'test_sample')
>>> drive = md.Drive(name='system_name', number=0, dirname=dirname)
>>> drive
OOMMFDrive(...)
Expand Down Expand Up @@ -120,8 +118,7 @@ def info(self):
>>> import os
>>> import micromagneticdata as md
...
>>> dirname = dirname=os.path.join(os.path.dirname(__file__),
... 'tests', 'test_sample')
>>> dirname = os.path.join(os.path.dirname(__file__), 'tests', 'test_sample')
>>> drive = md.Drive(name='system_name', number=6, dirname=dirname)
>>> drive.info
{...}
Expand Down
21 changes: 7 additions & 14 deletions micromagneticdata/data.py
Original file line number Diff line number Diff line change
Expand Up @@ -38,8 +38,7 @@ class Data:
>>> import os
>>> import micromagneticdata as md
...
>>> dirname = dirname=os.path.join(os.path.dirname(__file__),
... 'tests', 'test_sample')
>>> dirname = os.path.join(os.path.dirname(__file__), 'tests', 'test_sample')
>>> data = md.Data(name='system_name', dirname=dirname)
"""
Expand Down Expand Up @@ -69,8 +68,7 @@ def __repr__(self):
>>> import os
>>> import micromagneticdata as md
...
>>> dirname = dirname=os.path.join(os.path.dirname(__file__),
... 'tests', 'test_sample')
>>> dirname = os.path.join(os.path.dirname(__file__), 'tests', 'test_sample')
>>> data = md.Data(name='system_name', dirname=dirname)
>>> data
Data(...)
Expand Down Expand Up @@ -99,8 +97,7 @@ def info(self):
>>> import os
>>> import micromagneticdata as md
...
>>> dirname = dirname=os.path.join(os.path.dirname(__file__),
... 'tests', 'test_sample')
>>> dirname = os.path.join(os.path.dirname(__file__), 'tests', 'test_sample')
>>> data = md.Data(name='system_name', dirname=dirname)
>>> data.info
drive_number...
Expand All @@ -124,8 +121,7 @@ def n(self):
>>> import os
>>> import micromagneticdata as md
...
>>> dirname = dirname=os.path.join(os.path.dirname(__file__),
... 'tests', 'test_sample')
>>> dirname = os.path.join(os.path.dirname(__file__), 'tests', 'test_sample')
>>> data = md.Data(name='system_name', dirname=dirname)
>>> data.n
7
Expand Down Expand Up @@ -158,8 +154,7 @@ def __getitem__(self, item):
>>> import os
>>> import micromagneticdata as md
...
>>> dirname = dirname=os.path.join(os.path.dirname(__file__),
... 'tests', 'test_sample')
>>> dirname = os.path.join(os.path.dirname(__file__), 'tests', 'test_sample')
>>> data = md.Data(name='system_name', dirname=dirname)
>>> data.n
7
Expand Down Expand Up @@ -195,8 +190,7 @@ def __iter__(self):
>>> import os
>>> import micromagneticdata as md
...
>>> dirname = dirname=os.path.join(os.path.dirname(__file__),
... 'tests', 'test_sample')
>>> dirname = os.path.join(os.path.dirname(__file__), 'tests', 'test_sample')
>>> data = md.Data(name='system_name', dirname=dirname)
>>> data.n
7
Expand Down Expand Up @@ -232,8 +226,7 @@ def selector(self, description="drive", **kwargs):
>>> import os
>>> import micromagneticdata as md
...
>>> dirname = dirname=os.path.join(os.path.dirname(__file__),
... 'tests', 'test_sample')
>>> dirname = os.path.join(os.path.dirname(__file__), 'tests', 'test_sample')
>>> data = md.Data(name='system_name', dirname=dirname)
>>> data.selector()
BoundedIntText(...)
Expand Down
21 changes: 7 additions & 14 deletions micromagneticdata/drive.py
Original file line number Diff line number Diff line change
Expand Up @@ -63,8 +63,7 @@ class Drive(md.AbstractDrive):
>>> import os
>>> import micromagneticdata as md
...
>>> dirname = dirname=os.path.join(os.path.dirname(__file__),
... 'tests', 'test_sample')
>>> dirname = os.path.join(os.path.dirname(__file__), 'tests', 'test_sample')
>>> drive = md.Data(name='system_name', dirname=dirname)[0]
>>> drive
OOMMFDrive(...)
Expand Down Expand Up @@ -191,8 +190,7 @@ def __getitem__(self, item):
>>> import os
>>> import micromagneticdata as md
...
>>> dirname = dirname=os.path.join(os.path.dirname(__file__),
... 'tests', 'test_sample')
>>> dirname = os.path.join(os.path.dirname(__file__), 'tests', 'test_sample')
>>> drive = md.Drive(name='system_name', number=0, dirname=dirname)
>>> drive[5]
Field(...)
Expand All @@ -201,8 +199,7 @@ def __getitem__(self, item):
>>> import os
>>> import micromagneticdata as md
...
>>> dirname = dirname=os.path.join(os.path.dirname(__file__),
... 'tests', 'test_sample')
>>> dirname = os.path.join(os.path.dirname(__file__), 'tests', 'test_sample')
>>> drive = md.Drive(name='system_name', number=0, dirname=dirname)
>>> selection = drive[:8:2]
>>> selection
Expand Down Expand Up @@ -249,8 +246,7 @@ def info(self):
>>> import os
>>> import micromagneticdata as md
...
>>> dirname = dirname=os.path.join(os.path.dirname(__file__),
... 'tests', 'test_sample')
>>> dirname = os.path.join(os.path.dirname(__file__), 'tests', 'test_sample')
>>> drive = md.Drive(name='system_name', number=6, dirname=dirname)
>>> drive.info
{...}
Expand All @@ -277,8 +273,7 @@ def calculator_script(self):
>>> import os
>>> import micromagneticdata as md
...
>>> dirname = dirname=os.path.join(os.path.dirname(__file__),
... 'tests', 'test_sample')
>>> dirname = os.path.join(os.path.dirname(__file__), 'tests', 'test_sample')
>>> drive = md.Drive(name='system_name', number=6, dirname=dirname)
>>> drive.calculator_script
'# MIF 2...'
Expand Down Expand Up @@ -308,8 +303,7 @@ def ovf2vtk(self, dirname=None):
>>> import os
>>> import micromagneticdata as md
...
>>> dirname = dirname=os.path.join(os.path.dirname(__file__),
... 'tests', 'test_sample')
>>> dirname = os.path.join(os.path.dirname(__file__), 'tests', 'test_sample')
>>> drive = md.Drive(name='system_name', number=0, dirname=dirname)
>>> drive.ovf2vtk()
Expand Down Expand Up @@ -344,8 +338,7 @@ def slider(self, description="step", **kwargs):
>>> import os
>>> import micromagneticdata as md
...
>>> dirname = dirname=os.path.join(os.path.dirname(__file__),
... 'tests', 'test_sample')
>>> dirname = os.path.join(os.path.dirname(__file__), 'tests', 'test_sample')
>>> drive = md.Drive(name='system_name', number=0, dirname=dirname)
>>> drive.slider()
IntSlider(...)
Expand Down
6 changes: 2 additions & 4 deletions micromagneticdata/mumax3drive.py
Original file line number Diff line number Diff line change
Expand Up @@ -54,8 +54,7 @@ class Mumax3Drive(md.Drive):
>>> import os
>>> import micromagneticdata as md
...
>>> dirname = dirname=os.path.join(os.path.dirname(__file__),
... 'tests', 'test_sample')
>>> dirname = os.path.join(os.path.dirname(__file__), 'tests', 'test_sample')
>>> drive = md.Drive(name='system_name', number=1, dirname=dirname)
>>> drive
Mumax3Drive(...)
Expand Down Expand Up @@ -117,8 +116,7 @@ def __repr__(self):
>>> import os
>>> import micromagneticdata as md
...
>>> dirname = dirname=os.path.join(os.path.dirname(__file__),
... 'tests', 'test_sample')
>>> dirname = os.path.join(os.path.dirname(__file__), 'tests', 'test_sample')
>>> drive = md.Drive(name='system_name', number=1, dirname=dirname)
>>> drive
Mumax3Drive(name='system_name', number=1, dirname='...test_sample', x='t')
Expand Down
6 changes: 2 additions & 4 deletions micromagneticdata/oommfdrive.py
Original file line number Diff line number Diff line change
Expand Up @@ -52,8 +52,7 @@ class OOMMFDrive(md.Drive):
>>> import os
>>> import micromagneticdata as md
...
>>> dirname = dirname=os.path.join(os.path.dirname(__file__),
... 'tests', 'test_sample')
>>> dirname = os.path.join(os.path.dirname(__file__), 'tests', 'test_sample')
>>> drive = md.Drive(name='system_name', number=0, dirname=dirname)
"""
Expand Down Expand Up @@ -109,8 +108,7 @@ def __repr__(self):
>>> import os
>>> import micromagneticdata as md
...
>>> dirname = dirname=os.path.join(os.path.dirname(__file__),
... 'tests', 'test_sample')
>>> dirname = os.path.join(os.path.dirname(__file__), 'tests', 'test_sample')
>>> drive = md.Drive(name='system_name', number=0, dirname=dirname)
>>> drive
OOMMFDrive(name='system_name', number=0, dirname='...test_sample', x='t')
Expand Down

0 comments on commit 4938524

Please sign in to comment.