Changeset 646


Ignore:
Timestamp:
12/21/17 15:11:18 (6 years ago)
Author:
dubos
Message:

devel/unstructured : update some test cases

Location:
codes/icosagcm/devel/Python/test/py
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • codes/icosagcm/devel/Python/test/py/NH_3D_bubble.py

    r642 r646  
    5454 
    5555#Lx, nx, llm, thetac, T, Nslice, courant = 2000., 100, 50, 30., 5., 10, 2.8 
    56 Lx, nx, llm, thetac, T, Nslice, courant = 2000., 50, 25, 30, 5., 10, 2.8 
     56Lx, nx, llm, thetac, T, Nslice, courant = 2000., 8, 80, 30, 5., 10, 2.8 
    5757#Lx, nx, llm, thetac, T, Nslice, courant = 3000., 75, 25, -30, 5., 10, 2.8 
    5858 
     
    130130    m,S,u,Phi,W = next_flow(m,S,u,Phi,W) 
    131131    time2, elapsed2 =time.time(), unst.getvar('elapsed') 
    132     factor = 1000./(4*nt) 
    133     print 'ms per call to caldyn_hevi : ', factor*(time2-time1), factor*(elapsed2-elapsed1) 
     132    factor = 1000./nt 
     133    print 'ms per full time step : ', factor*(time2-time1), factor*(elapsed2-elapsed1) 
    134134    factor = 1e9/(4*nt*nx*ny*llm) 
    135     print 'nanosec per gridpoint per call to caldyn_hevi : ', factor*(time2-time1), factor*(elapsed2-elapsed1) 
     135    print 'nanosec per gridpoint per full time step : ', factor*(time2-time1), factor*(elapsed2-elapsed1) 
    136136         
  • codes/icosagcm/devel/Python/test/py/slice_GW_NH.py

    r631 r646  
    11from dynamico.meshes import Cartesian_mesh as Mesh 
     2from dynamico import meshes 
    23from dynamico import unstructured as unst 
    34from dynamico import dyn 
     
    1516    caldyn_thermo = unst.thermo_entropy 
    1617    g = mesh.dx/metric.dx_g0 
    17     caldyn = unst.Caldyn_NH(caldyn_thermo,caldyn_eta, mesh,metric,thermo,BC,g) 
     18    caldyn = unst.Caldyn_NH(caldyn_thermo,caldyn_eta, mesh,thermo,BC,g) 
    1819 
    1920    Sik = m0ik*gas0.s 
     
    9596xx,ll = mesh.xx[:,0,:]/1000, mesh.ll[:,0,:] 
    9697 
    97 #metric, thermo, BC, m0ik, gas0, Phi0_il, u0_jk = DCMIP.DCMIP31(Lx, nx, llm, deform=deform, dTheta=1.) 
    98 metric, thermo, BC, m0ik, gas0, Phi0_il, u0_jk = DCMIP.DCMIP21(Lx, nx, llm, deform=deform, h0=0.) 
     98metric, thermo, BC, m0ik, gas0, Phi0_il, u0_jk = DCMIP.DCMIP31(Lx, nx, llm, deform=deform, dTheta=1.) 
     99#metric, thermo, BC, m0ik, gas0, Phi0_il, u0_jk = DCMIP.DCMIP21(Lx, nx, llm, deform=deform, h0=0.) 
    99100 
    100101BC.rho_bot = 1e6*BC.rho_bot # large stiffness 
    101102 
    102 mass_bl,mass_dak,mass_dbk = unst.compute_hybrid_coefs(m0ik) 
    103 unst.init_hybrid(mass_bl,mass_dak,mass_dbk) 
     103mass_bl,mass_dak,mass_dbk = meshes.compute_hybrid_coefs(m0ik) 
     104unst.ker.dynamico_init_hybrid(mass_bl,mass_dak,mass_dbk) 
    104105 
    105106run(mesh,metric,thermo,BC,unst.eta_mass,20.,  m0ik,gas0,Phi0_il, courant=2.) # lower courant number required if h0=2000m 
  • codes/icosagcm/devel/Python/test/py/slice_GW_hydro.py

    r642 r646  
    99import numpy as np 
    1010import time 
    11  
    12 unst.setvar('nb_threads', 1) 
    1311 
    1412def run(mesh,metric,thermo,BC,caldyn_eta, m0ik,gas0): 
Note: See TracChangeset for help on using the changeset viewer.