Changes in src/FLEXPART_MPI.f90 [0c00f1f:20963b1] in flexpart.git
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
src/FLEXPART_MPI.f90
r0c00f1f r20963b1 53 53 use conv_mod 54 54 use mpi_mod 55 use netcdf_output_mod, only: writeheader_netcdf56 55 use random_mod, only: gasdev1 57 56 use class_gribfile 57 58 #ifdef USE_NCF 59 use netcdf_output_mod, only: writeheader_netcdf 60 #endif 58 61 59 62 implicit none … … 64 67 integer :: metdata_format = GRIBFILE_CENTRE_UNKNOWN 65 68 integer :: detectformat 66 69 integer(selected_int_kind(16)), dimension(maxspec) :: tot_b=0, & 70 & tot_i=0 67 71 68 72 … … 203 207 204 208 if (metdata_format.eq.GRIBFILE_CENTRE_ECMWF) then 205 print *,'ECMWF metdata detected'209 if (lroot) print *,'ECMWF metdata detected' 206 210 elseif (metdata_format.eq.GRIBFILE_CENTRE_NCEP) then 207 print *,'NCEP metdata detected'211 if (lroot) print *,'NCEP metdata detected' 208 212 else 209 print *,'Unknown metdata format'213 if (lroot) print *,'Unknown metdata format' 210 214 stop 211 215 endif … … 378 382 379 383 if (mp_measure_time) call mpif_mtime('iotime',0) 384 380 385 if (lroot) then ! MPI: this part root process only 381 382 if (lnetcdfout.eq.1) then383 call writeheader_netcdf(lnest=.false.)384 else385 call writeheader386 end if387 388 if (nested_output.eq.1) then389 if (lnetcdfout.eq.1) then390 call writeheader_netcdf(lnest=.true.)391 else392 call writeheader_nest393 endif394 endif395 396 ! 386 #ifdef USE_NCF 387 if (lnetcdfout.eq.1) then 388 call writeheader_netcdf(lnest=.false.) 389 else 390 call writeheader 391 end if 392 393 if (nested_output.eq.1) then 394 if (lnetcdfout.eq.1) then 395 call writeheader_netcdf(lnest=.true.) 396 else 397 call writeheader_nest 398 endif 399 endif 400 #endif 401 397 402 if (verbosity.gt.0) then 398 403 print*,'call writeheader' … … 402 407 ! FLEXPART 9.2 ticket ?? write header in ASCII format 403 408 call writeheader_txt 404 !if (nested_output.eq.1) call writeheader_nest 409 405 410 if (nested_output.eq.1.and.surf_only.ne.1) call writeheader_nest 406 411 if (nested_output.eq.1.and.surf_only.eq.1) call writeheader_nest_surf … … 409 414 410 415 if (mp_measure_time) call mpif_mtime('iotime',0) 411 412 !open(unitdates,file=path(2)(1:length(2))//'dates')413 416 414 417 if (verbosity.gt.0 .and. lroot) then … … 481 484 482 485 ! NIK 16.02.2005 483 if ( lroot) then484 call MPI_Reduce( MPI_IN_PLACE, tot_blc_count, nspec, MPI_INTEGER8, MPI_SUM, id_root, &486 if (mp_partgroup_pid.ge.0) then ! Skip for readwind process 487 call MPI_Reduce(tot_blc_count, tot_b, nspec, MPI_INTEGER8, MPI_SUM, id_root, & 485 488 & mp_comm_used, mp_ierr) 486 call MPI_Reduce( MPI_IN_PLACE, tot_inc_count, nspec, MPI_INTEGER8, MPI_SUM, id_root, &489 call MPI_Reduce(tot_inc_count, tot_i, nspec, MPI_INTEGER8, MPI_SUM, id_root, & 487 490 & mp_comm_used, mp_ierr) 488 else489 if (mp_partgroup_pid.ge.0) then ! Skip for readwind process490 call MPI_Reduce(tot_blc_count, 0, nspec, MPI_INTEGER8, MPI_SUM, id_root, &491 & mp_comm_used, mp_ierr)492 call MPI_Reduce(tot_inc_count, 0, nspec, MPI_INTEGER8, MPI_SUM, id_root, &493 & mp_comm_used, mp_ierr)494 end if495 491 end if 492 496 493 497 494 if (lroot) then … … 500 497 write(*,*) 'Scavenging statistics for species ', species(i), ':' 501 498 write(*,*) 'Total number of occurences of below-cloud scavenging', & 502 & tot_blc_count(i) 499 & tot_b(i) 500 ! & tot_blc_count(i) 503 501 write(*,*) 'Total number of occurences of in-cloud scavenging', & 504 & tot_inc_count(i) 502 & tot_i(i) 503 ! & tot_inc_count(i) 505 504 write(*,*) '**********************************************' 506 505 end do
Note: See TracChangeset
for help on using the changeset viewer.