|
libsim Versione 8.0.0
|
◆ arrayof_ttr_mapper_insert_array()
Method for inserting a number of elements of the array at a desired position. If necessary, the array is reallocated to accomodate the new elements.
Definizione alla linea 496 del file stat_proc_engine.F90. 497
498! euristically determine whether we are dealing with an
499! analysis/observation or a forecast dataset
500na = count(mask_timerange(:) .AND. itimerange(:)%p1 == 0)
501nf = count(mask_timerange(:) .AND. itimerange(:)%p1 > 0)
502lforecast = nf >= na
503#ifdef DEBUG
504CALL l4f_log(l4f_debug, &
505 'recompute_stat_proc_agg, na: '//t2c(na)//', nf: '//t2c(nf))
506#endif
507
508! keep only timeranges of one type (really necessary?)
509IF (lforecast) THEN
510 CALL l4f_log(l4f_info, &
511 'recompute_stat_proc_agg, processing in forecast mode')
512ELSE
513 mask_timerange(:) = mask_timerange(:) .AND. itimerange(:)%p1 == 0
514 CALL l4f_log(l4f_info, &
515 'recompute_stat_proc_agg, processing in analysis mode')
516ENDIF
517
518#ifdef DEBUG
519CALL l4f_log(l4f_debug, &
520 '(re)compute_stat_proc_agg, number of useful timeranges: '// &
521 t2c(count(mask_timerange)))
522#endif
523
524IF (SIZE(itime) == 0 .OR. count(mask_timerange) == 0) THEN ! avoid segmentation fault in case of empty volume
525 ALLOCATE(otime(0), otimerange(0), map_ttr(0,0))
526 IF (PRESENT(dtratio)) ALLOCATE(dtratio(0))
527 RETURN
528ENDIF
529
530! determine start and end of processing period, should work with p2==0
|