PlasmaCalcs
Usage
PlasmaCalcs API
plasma_calculator
quantities
dimensions
units
hookups
addons
other_calculators
mhd
multi_run_analysis
tools
array_select
arrays
display
docs_tools
fft_tools
history
imports
io_tools
iterables
math
multiprocessing
oop_tools
os_tools
find_files_re
get_paths_with_common_start
maintain_cwd
maintain_dir
maintain_directory
nbytes_path
next_unique_name
pc_path
with_dir
InDir
properties
pytools
sentinels
supercomputer
timing
trees
xarray_tools
plotting
defaults
errors
PlasmaCalcs
PlasmaCalcs API
tools
os_tools
InDir
View page source
InDir
class
PlasmaCalcs.tools.os_tools.
InDir
(
directory
=
'.'
)
Bases:
object
context manager for remembering directory.
upon enter, cd to directory (default os.curdir, i.e. no change in directory)
upon exit, original working directory will be restored.
For function decorator, see tools.maintain_cwd.