docs: def create_session(docker_image=None,
                     docker_rm=None,
                     echo=False,
                     loglevel='WARNING',
                     nocolor=False,
                     session_type='bash',
                     vagrant_session_name=None,
                     vagrant_image='ubuntu/xenial64',
                     vagrant_gui=False,
                     vagrant_memory='1024',
                     vagrant_num_machines='1',
                     vagrant_provider='virtualbox',
                     vagrant_root_folder=None,
                     vagrant_swapsize='2G',
                     vagrant_version='1.8.6',
                     vagrant_virt_method='virtualbox',
                     vagrant_cpu='1',
                     video=-1,
                     walkthrough=False):
  	"""Creates a distinct ShutIt session. Sessions can be of type:
  
  	bash    - a bash shell is spawned and
  	vagrant - a Vagrantfile is created and 'vagrant up'ped
  	"""
  	assert session_type in ('bash','docker','vagrant'), shutit_util.print_debug()
  	shutit_global_object = shutit_global.shutit_global_object
  	if video != -1 and video > 0:
  		walkthrough = True
  	if session_type in ('bash','docker'):
  		return shutit_global_object.create_session(session_type,
  		                                           docker_image=docker_image,
  		                                           rm=docker_rm,
  		                                           echo=echo,
  		                                           walkthrough=walkthrough,
  		                                           walkthrough_wait=video,
  		                                           nocolor=nocolor,
  		                                           loglevel=loglevel)
  	elif session_type == 'vagrant':
  		if vagrant_session_name is None:
  			vagrant_session_name = 'shutit' + shutit_util.random_id()
  		if isinstance(vagrant_num_machines, int):
  			vagrant_num_machines = str(vagrant_num_machines)
  		assert isinstance(vagrant_num_machines, str)
  		assert isinstance(int(vagrant_num_machines), int)
  		if vagrant_root_folder is None:
  			vagrant_root_folder = shutit_global.shutit_global_object.owd
  		return create_session_vagrant(vagrant_session_name,
  		                              vagrant_num_machines,
  		                              vagrant_image,
  		                              vagrant_provider,
  		                              vagrant_gui,
  		                              vagrant_memory,
  		                              vagrant_swapsize,
  		                              echo,
  		                              walkthrough,
  		                              nocolor,
  		                              video,
  		                              vagrant_version,
  		                              vagrant_virt_method,
  		                              vagrant_root_folder,
  		                              vagrant_cpu,
  		                              loglevel)