Index: /issm/trunk-jpl/src/m/classes/clusters/cyclone.py
===================================================================
--- /issm/trunk-jpl/src/m/classes/clusters/cyclone.py	(revision 24268)
+++ /issm/trunk-jpl/src/m/classes/clusters/cyclone.py	(revision 24269)
@@ -73,5 +73,5 @@
         #write queuing script
         fid = open(modelname + '.queue', 'w')
-        fid.write('export ISSM_DIR = "%s/../ "\n' % self.codepath)
+        fid.write('export ISSM_DIR="%s/../ "\n' % self.codepath)
         fid.write('source $ISSM_DIR/etc/environment.sh\n')
         fid.write('INTELLIBS = "/opt/intel/intelcompiler-12.04/composerxe-2011.4.191/compiler/lib/intel64"\n')
Index: /issm/trunk-jpl/src/m/classes/clusters/hexagon.py
===================================================================
--- /issm/trunk-jpl/src/m/classes/clusters/hexagon.py	(revision 24268)
+++ /issm/trunk-jpl/src/m/classes/clusters/hexagon.py	(revision 24269)
@@ -107,6 +107,6 @@
         fid.write('#PBS -o %s/%s/%s.outlog \n' % (self.executionpath, dirname, modelname))
         fid.write('#PBS -e %s/%s/%s.errlog \n\n' % (self.executionpath, dirname, modelname))
-        fid.write('export ISSM_DIR = "%s/../"\n' % self.codepath)
-        fid.write('export CRAY_ROOTFS = DSL\n')
+        fid.write('export ISSM_DIR="%s/../"\n' % self.codepath)
+        fid.write('export CRAY_ROOTFS=DSL\n')
         fid.write('module swap PrgEnv-cray / 5.2.40 PrgEnv - gnu\n')
         fid.write('module load cray-petsc\n')
Index: /issm/trunk-jpl/src/m/classes/clusters/pfe.py
===================================================================
--- /issm/trunk-jpl/src/m/classes/clusters/pfe.py	(revision 24268)
+++ /issm/trunk-jpl/src/m/classes/clusters/pfe.py	(revision 24269)
@@ -150,7 +150,7 @@
         fid.write('module load comp-intel/2015.0.090\n')
         fid.write('module load mpi-sgi/mpt.2.11r13\n')
-        fid.write('export PATH = "$PATH:."\n\n')
-        fid.write('export MPI_GROUP_MAX = 64\n\n')
-        fid.write('export ISSM_DIR = "%s/../ "\n' % self.codepath)
+        fid.write('export PATH="$PATH:."\n\n')
+        fid.write('export MPI_GROUP_MAX=64\n\n')
+        fid.write('export ISSM_DIR="%s/../ "\n' % self.codepath)
         fid.write('source $ISSM_DIR/etc/environment.sh\n')
         fid.write('cd %s/%s/ \n\n' % (self.executionpath, dirname))
Index: /issm/trunk-jpl/src/m/classes/clusters/stallo.py
===================================================================
--- /issm/trunk-jpl/src/m/classes/clusters/stallo.py	(revision 24268)
+++ /issm/trunk-jpl/src/m/classes/clusters/stallo.py	(revision 24269)
@@ -124,5 +124,5 @@
         fid.write('#SBATCH --error %s/%s/%s.errlog \n\n' % (self.executionpath, dirname, modelname))
 
-        fid.write('export ISSM_DIR = "%s/../"\n' % self.codepath)
+        fid.write('export ISSM_DIR="%s/../"\n' % self.codepath)
         fid.write('module purge\n')
         fid.write('module load CMake/3.8.0-GCCcore-6.3.0\n')
Index: /issm/trunk-jpl/src/m/classes/clusters/vilje.py
===================================================================
--- /issm/trunk-jpl/src/m/classes/clusters/vilje.py	(revision 24268)
+++ /issm/trunk-jpl/src/m/classes/clusters/vilje.py	(revision 24269)
@@ -108,5 +108,5 @@
         fid.write('#PBS -o %s/%s/%s.outlog \n' % (self.executionpath, dirname, modelname))
         fid.write('#PBS -e %s/%s/%s.errlog \n\n' % (self.executionpath, dirname, modelname))
-        fid.write('export ISSM_DIR = "%s/../ "\n' % self.codepath)
+        fid.write('export ISSM_DIR="%s/../ "\n' % self.codepath)
         fid.write('module load intelcomp/17.0.0\n')
         fid.write('module load mpt/2.14\n')
Index: /issm/trunk-jpl/src/m/classes/pairoptions.py
===================================================================
--- /issm/trunk-jpl/src/m/classes/pairoptions.py	(revision 24268)
+++ /issm/trunk-jpl/src/m/classes/pairoptions.py	(revision 24269)
@@ -1,4 +1,3 @@
 from collections import OrderedDict
-
 
 class pairoptions(object):
@@ -31,6 +30,7 @@
         if self.list:
             s += "   list: ({}x{}) \n\n".format(len(self.list), 2)
-            for item in list(self.list.items()):
-                s += "     field: {} value: '{}'\n".format((item[0], item[1]))
+            for item in self.list.items():
+                s += "     field: {} value: '{}'\n".format(item[0], item[1])
+            print(s)
         else:
             s += "   list: empty\n"
Index: /issm/trunk-jpl/src/m/classes/plotoptions.py
===================================================================
--- /issm/trunk-jpl/src/m/classes/plotoptions.py	(revision 24268)
+++ /issm/trunk-jpl/src/m/classes/plotoptions.py	(revision 24269)
@@ -26,11 +26,6 @@
             s += "    list: (%ix%i)\n" % (len(self.list), 2)
             for item in list(self.list.items()):
-                #s += "    options of plot number %i\n" % item
-                if isinstance(item[1], str):
-                    s += "    field: % - 10s value: '%s'\n" % (item[0], item[1])
-                elif isinstance(item[1], (bool, int, float)):
-                    s += "    field: % - 10s value: '%g'\n" % (item[0], item[1])
-                else:
-                    s += "    field: % - 10s value: '%s'\n" % (item[0], item[1])
+                s += "    field: {:10} value: '{}'\n".format(item[0], item[1])
+            print(s)
         else:
             s += "    list: empty\n"
Index: /issm/trunk-jpl/src/m/contrib/defleurian/paraview/exportVTK.py
===================================================================
--- /issm/trunk-jpl/src/m/contrib/defleurian/paraview/exportVTK.py	(revision 24268)
+++ /issm/trunk-jpl/src/m/contrib/defleurian/paraview/exportVTK.py	(revision 24269)
@@ -108,6 +108,21 @@
         num_of_points = every_nodes
         if dim == 2:
-            points = np.column_stack((md.mesh.x, md.mesh.y, md.geometry.surface))
+            mesh_alti = input('''This is a 2D model, what should be the 3rd dimension of the mesh :
+                                        1 : md.geometry.surface
+                                        2 : md.geometry.base
+                                        3 : md.geometry.bed
+                                        4 : 0\n''')
+            if mesh_alti == 1:
+                points = np.column_stack((md.mesh.x, md.mesh.y, md.geometry.surface))
+            elif mesh_alti == 2:
+                points = np.column_stack((md.mesh.x, md.mesh.y, md.geometry.base))
+            elif mesh_alti == 3:
+                points = np.column_stack((md.mesh.x, md.mesh.y, md.geometry.bed))
+            elif mesh_alti == 4:
+                points = np.column_stack((md.mesh.x, md.mesh.y, 0. * md.mesh.x))
+            else:
+                points = np.column_stack((md.mesh.x, md.mesh.y, md.geometry.surface))
         elif dim == 3:
+            mesh_alti = 1
             points = np.column_stack((md.mesh.x, md.mesh.y, md.mesh.z))
         else:
@@ -127,5 +142,5 @@
         fid.write('POINTS {:d} float\n'.format(num_of_points))
     #updating z for mesh evolution
-        if moving_mesh:
+        if moving_mesh and mesh_alti in [1, 2]:
             base = np.squeeze(res_struct.__dict__['TransientSolution'][step].__dict__['Base'][enveloppe_index])
             thick_change_ratio = (np.squeeze(res_struct.__dict__['TransientSolution'][step].__dict__['Thickness'][enveloppe_index]) / md.geometry.thickness[enveloppe_index])
@@ -242,8 +257,10 @@
                                 fid.write('{:f} {:f} {:f}\n'.format(0, 0, 0))
                     else:
-                        if (np.size(spe_res_struct.__dict__[field]) == 1):
+                        if np.size(spe_res_struct.__dict__[field]) == 1:
+                            if field == 'time':
+                                current_time = spe_res_struct.__dict__[field]
                             #skipping integers
                             continue
-                        elif ((np.size(spe_res_struct.__dict__[field])) == every_nodes):
+                        elif np.size(spe_res_struct.__dict__[field]) == every_nodes:
                             fid.write('SCALARS {} float 1 \n'.format(field))
                             fid.write('LOOKUP_TABLE default\n')
@@ -251,5 +268,5 @@
                                 outval = cleanOutliers(np.squeeze(spe_res_struct.__dict__[field][enveloppe_index[node]]))
                                 fid.write('{:f}\n'.format(outval))
-                        elif (np.shape(spe_res_struct.__dict__[field])[0] == np.size(spe_res_struct.__dict__[field]) == every_cells):
+                        elif np.shape(spe_res_struct.__dict__[field])[0] == np.size(spe_res_struct.__dict__[field]) == every_cells:
                             saved_cells[field] = np.squeeze(spe_res_struct.__dict__[field])
                         else:
@@ -262,8 +279,8 @@
             othernames = (dict.keys(other_struct.__dict__))
             for field in othernames:
-                if (np.size(other_struct.__dict__[field]) == 1):
+                if np.size(other_struct.__dict__[field]) == 1:
                     #skipping integers
                     continue
-                elif (np.size(other_struct.__dict__[field]) == every_nodes):
+                elif np.size(other_struct.__dict__[field]) == every_nodes:
                     fid.write('SCALARS {} float 1 \n'.format(field))
                     fid.write('LOOKUP_TABLE default\n')
@@ -271,5 +288,28 @@
                         outval = cleanOutliers(other_struct.__dict__[field][enveloppe_index[node]])
                         fid.write('{:f}\n'.format(outval))
-                elif (np.shape(other_struct.__dict__[field])[0] == np.size(other_struct.__dict__[field]) == every_cells):
+                elif np.shape(other_struct.__dict__[field])[0] == every_nodes + 1:
+                    #we are dealing with a forcing of some kind.
+                    forcing_time = other_struct.__dict__[field][-1, :]
+                    if any(forcing_time == current_time):
+                        forcing_index = np.where(forcing_time == current_time)
+                        forcing_val = other_struct.__dict__[field][:, forcing_index]
+                    elif forcing_time[0] > current_time:
+                        forcing_val = other_struct.__dict__[field][:, 0]
+                    elif forcing_time[-1] < current_time:
+                        forcing_val = other_struct.__dict__[field][:, -1]
+                    else:
+                        forcing_index = np.where(forcing_time < current_time)[-1][-1]
+                        delta_time = forcing_time[forcing_index + 1] - forcing_time[forcing_index]  #compute forcing Dt
+                        delta_current = current_time - forcing_time[forcing_index]  # time since last forcing
+                        ratio = delta_current / delta_time  #compute weighting factor for preceding forcing vallue
+                        forcing_evol = (other_struct.__dict__[field][:, forcing_index + 1] - other_struct.__dict__[field][:, forcing_index]) * ratio
+                        forcing_val = other_struct.__dict__[field][:, forcing_index] + forcing_evol
+                    # and now write it down
+                    fid.write('SCALARS {}_{} float 1 \n'.format(other, field))
+                    fid.write('LOOKUP_TABLE default\n')
+                    for node in range(0, num_of_points):
+                        outval = cleanOutliers(forcing_val[enveloppe_index[node]])
+                        fid.write('{:f}\n'.format(outval))
+                elif np.shape(other_struct.__dict__[field])[0] == np.size(other_struct.__dict__[field]) == every_cells:
                     saved_cells[field] = other_struct.__dict__[field]
                 else:
Index: /issm/trunk-jpl/src/m/plot/plot_BC.py
===================================================================
--- /issm/trunk-jpl/src/m/plot/plot_BC.py	(revision 24268)
+++ /issm/trunk-jpl/src/m/plot/plot_BC.py	(revision 24269)
@@ -51,7 +51,5 @@
                 slicesize = len(x)
                 fulldata = md.__dict__[str(spc_dict[str(key)][0])].__dict__[str(key)]
-                print(key)
                 data = fulldata[(plotlayer - 1) * slicesize:plotlayer * slicesize]
-                print(np.shape(data))
                 mark = spc_dict[str(key)][1]
                 color = spc_dict[str(key)][2]
Index: /issm/trunk-jpl/src/m/plot/plot_manager.py
===================================================================
--- /issm/trunk-jpl/src/m/plot/plot_manager.py	(revision 24268)
+++ /issm/trunk-jpl/src/m/plot/plot_manager.py	(revision 24269)
@@ -35,5 +35,4 @@
     See also: PLOTMODEL, PLOT_UNIT
     '''
-
     #parse options and get a structure of options
     options = checkplotoptions(md, options)
Index: /issm/trunk-jpl/src/m/plot/plot_unit.py
===================================================================
--- /issm/trunk-jpl/src/m/plot/plot_unit.py	(revision 24268)
+++ /issm/trunk-jpl/src/m/plot/plot_unit.py	(revision 24269)
@@ -22,9 +22,7 @@
     """
     #if we are plotting 3d replace the current axis
-    print(is2d)
     if not is2d:
         axgrid[gridindex].axis('off')
         ax = inset_locator.inset_axes(axgrid[gridindex], width='100%', height='100%', loc=3, borderpad=0, axes_class=Axes3D)
-        ax.set_axis_bgcolor((0.7, 0.7, 0.7))
     else:
         ax = axgrid[gridindex]
Index: /issm/trunk-jpl/src/m/plot/plotmodel.py
===================================================================
--- /issm/trunk-jpl/src/m/plot/plotmodel.py	(revision 24268)
+++ /issm/trunk-jpl/src/m/plot/plotmodel.py	(revision 24269)
@@ -17,5 +17,4 @@
     #First process options
     options = plotoptions(*args)
-
     #get number of subplots
     subplotwidth = ceil(sqrt(options.numberofplots))
@@ -97,7 +96,10 @@
             for ax in axgrid.cbar_axes:
                 fig._axstack.remove(ax)
-
         for i, ax in enumerate(axgrid.axes_all):
-            plot_manager(options.list[i].getfieldvalue('model', md), options.list[i], fig, axgrid, i)
+            try:
+                plot_manager(options.list[i].getfieldvalue('model', md), options.list[i], fig, axgrid, i)
+            except KeyError:
+                print("Too many axes present, we delete the overflow")
+                fig.delaxes(axgrid[i])
         fig.show()
     else:
