1
0
mirror of https://github.com/saitohirga/WSJT-X.git synced 2025-03-23 20:48:33 -04:00

Deactivate a bunch of diagnostic wtites to console.

This commit is contained in:
Joe Taylor 2024-01-18 10:19:30 -05:00
parent ae64b71498
commit 3a5da4b2ac
4 changed files with 26 additions and 140 deletions

View File

@ -1,115 +0,0 @@
subroutine four2a(a,nfft,ndim,isign,iform)
! IFORM = 1, 0 or -1, as data is
! complex, real, or the first half of a complex array. Transform
! values are returned in array DATA. They are complex, real, or
! the first half of a complex array, as IFORM = 1, -1 or 0.
! The transform of a real array (IFORM = 0) dimensioned N(1) by N(2)
! by ... will be returned in the same array, now considered to
! be complex of dimensions N(1)/2+1 by N(2) by .... Note that if
! IFORM = 0 or -1, N(1) must be even, and enough room must be
! reserved. The missing values may be obtained by complex conjugation.
! The reverse transformation of a half complex array dimensioned
! N(1)/2+1 by N(2) by ..., is accomplished by setting IFORM
! to -1. In the N array, N(1) must be the true N(1), not N(1)/2+1.
! The transform will be real and returned to the input array.
! This version of four2a makes calls to the FFTW library to do the
! actual computations.
use fftw3
parameter (NPMAX=2100) !Max numberf of stored plans
parameter (NSMALL=16384) !Max size of "small" FFTs
complex a(nfft+1) !Array to be transformed
complex aa(NSMALL) !Local copy of "small" a()
integer nn(NPMAX),ns(NPMAX),nf(NPMAX) !Params of stored plans
integer*8 nl(NPMAX),nloc !More params of plans
integer*8 plan(NPMAX) !Pointers to stored plans
logical found_plan
data nplan/0/ !Number of stored plans
common/patience/npatience,nthreads !Patience and threads for FFTW plans
save plan,nplan,nn,ns,nf,nl
if(nfft.lt.0) go to 999
nloc=loc(a)
found_plan = .false.
!$omp critical(four2a_setup)
do i=1,nplan
if(nfft.eq.nn(i) .and. isign.eq.ns(i) .and. &
iform.eq.nf(i) .and. nloc.eq.nl(i)) then
found_plan = .true.
exit
end if
enddo
if(i.ge.NPMAX) stop 'Too many FFTW plans requested.'
if (.not. found_plan) then
nplan=nplan+1
i=nplan
nn(i)=nfft
ns(i)=isign
nf(i)=iform
nl(i)=nloc
! Planning: FFTW_ESTIMATE, FFTW_ESTIMATE_PATIENT, FFTW_MEASURE,
! FFTW_PATIENT, FFTW_EXHAUSTIVE
nflags=FFTW_ESTIMATE
if(npatience.eq.1) nflags=FFTW_ESTIMATE_PATIENT
if(npatience.eq.2) nflags=FFTW_MEASURE
if(npatience.eq.3) nflags=FFTW_PATIENT
if(npatience.eq.4) nflags=FFTW_EXHAUSTIVE
if(nfft.le.NSMALL) then
jz=nfft
if(iform.eq.0) jz=nfft/2
aa(1:jz)=a(1:jz)
endif
!$omp critical(fftw) ! serialize non thread-safe FFTW3 calls
if(isign.eq.-1 .and. iform.eq.1) then
call sfftw_plan_dft_1d(plan(i),nfft,a,a,FFTW_FORWARD,nflags)
else if(isign.eq.1 .and. iform.eq.1) then
call sfftw_plan_dft_1d(plan(i),nfft,a,a,FFTW_BACKWARD,nflags)
else if(isign.eq.-1 .and. iform.eq.0) then
call sfftw_plan_dft_r2c_1d(plan(i),nfft,a,a,nflags)
else if(isign.eq.1 .and. iform.eq.-1) then
call sfftw_plan_dft_c2r_1d(plan(i),nfft,a,a,nflags)
else
stop 'Unsupported request in four2a'
endif
!$omp end critical(fftw)
if(nfft.le.NSMALL) then
jz=nfft
if(iform.eq.0) jz=nfft/2
a(1:jz)=aa(1:jz)
endif
end if
!$omp end critical(four2a_setup)
call sfftw_execute(plan(i))
return
999 continue
!$omp critical(four2a)
do i=1,nplan
! The test is only to silence a compiler warning:
if(ndim.ne.-999) then
!$omp critical(fftw) ! serialize non thread-safe FFTW3 calls
call sfftw_destroy_plan(plan(i))
!$omp end critical(fftw)
end if
enddo
nplan=0
!$omp end critical(four2a)
return
end subroutine four2a

View File

@ -133,8 +133,8 @@ subroutine q65b(nutc,nqd,fcenter,nfcal,nfsample,ikhz,mousedf,ntol, &
freq1=freq0 + 0.001d0*(ikhz1-ikhz)
frx=0.001*k0*df+nkhz_center-48.0+1.0 - 0.001*nfcal
fsked=frx - 0.001*ndop00/2.0 - 0.001*offset
if(iand(nCFOM,2).eq.2) write(*,3001) nCFOM,ndop00,frx,fsked
3001 format('A',i5,i8,f10.3,f10.1)
! if(iand(nCFOM,2).eq.2) write(*,3001) nCFOM,ndop00,frx,fsked
!3001 format('A',i5,i8,f10.3,f10.1)
ctmp=csubmode//' '//trim(msg0)
ndecodes=min(ndecodes+1,50)
write(result(ndecodes),1120) nhhmmss,frx,fsked,xdt0,nsnr0,trim(ctmp)

View File

@ -12,7 +12,7 @@ subroutine q65c
real*8 fcenter
real*4 pdb(4)
integer nparams0(NJUNK+3),nparams(NJUNK+3)
integer values(8)
! integer values(8)
logical first
logical*1 bAlso30
character*120 fname
@ -79,18 +79,18 @@ subroutine q65c
call timer('decode0 ',1)
10 continue
call date_and_time(VALUES=values)
n60b=values(7)
nd=n60b-n60
if(nd.lt.0) nd=nd+60
write(*,3002) nutc,nagain,nhsym,n60,n60b,nd,ntx30a,ntx30b,ndecodes, &
nsave,revision
3002 format('A',i5.4,i3,i5,7i4,1x,a22)
flush(6)
! call date_and_time(VALUES=values)
! n60b=values(7)
! nd=n60b-n60
! if(nd.lt.0) nd=nd+60
! write(*,3002) nutc,nagain,nhsym,n60,n60b,nd,ntx30a,ntx30b,ndecodes, &
! nsave,revision
!3002 format('A',i5.4,i3,i5,7i4,1x,a22)
! flush(6)
if(ndiskdat.eq.0) then
if(nhsym.eq.390 .and. (nsave.eq.2 .or. &
(nsave.eq.1 .and. ndecodes.ge.1))) then
if(nhsym.eq.390 .and. &
(nsave.eq.2 .or. (nsave.eq.1 .and. ndecodes.ge.1))) then
call save_qm(fname,revision,mycall,mygrid,dd,ntx30a,ntx30b,fcenter, &
nutc,ndop00,ndop58)
endif

View File

@ -402,13 +402,14 @@ void MainWindow::dataSink(int k)
bool bCallDecoder=false;
if(ihsym < m_hsymStop) m_decode_called=false;
if(ihsym==m_hsymStop and !m_decode_called) bCallDecoder=true; //Decode at t=58.5 s
if(m_bAlso30 and (ihsym==200) and (m_n60==30)) bCallDecoder=true;
if((ihsym==330) and (m_n60==49)) bCallDecoder=true;
if(m_bAlso30 and (ihsym==200)) bCallDecoder=true;
if(ihsym==330) bCallDecoder=true;
if(ihsym==ihsym0) bCallDecoder=false;
if((ihsym!=ihsym0+1) or (qAbs(ihsym-200)<3) or (qAbs(ihsym-330)<4) or (qAbs(ihsym-390)<4)) {
qDebug() << "aa" << ihsym0 << ihsym << m_n60
<< bCallDecoder << 0.001*(QDateTime::currentMSecsSinceEpoch()%60000);
}
// if((ihsym!=ihsym0+1) or (qAbs(ihsym-200)<3) or (qAbs(ihsym-330)<3) or (qAbs(ihsym-390)<3)) {
// qDebug() << "aa" << ihsym0 << ihsym << m_n60
// << bCallDecoder << 0.001*(QDateTime::currentMSecsSinceEpoch()%60000);
// }
ihsym0=ihsym;
if(bCallDecoder) {
@ -742,7 +743,7 @@ void MainWindow::diskDat(int iret) //diskDat()
void MainWindow::decoderFinished()
{
qDebug() << "ee" << "decoder finished" << 0.001*(QDateTime::currentMSecsSinceEpoch()%60000);
// qDebug() << "ee" << "decoder finished" << 0.001*(QDateTime::currentMSecsSinceEpoch()%60000);
m_startAnother=m_loopall;
decodes_.nQDecoderDone=1;
if(m_diskData) decodes_.nQDecoderDone=2;
@ -844,8 +845,8 @@ void MainWindow::freezeDecode(int n) //freezeDecode()
void MainWindow::decode() //decode()
{
qDebug() << "bb" << "decoder called" << m_decoderBusy
<< 0.001*(QDateTime::currentMSecsSinceEpoch()%60000);
// qDebug() << "bb" << "decoder called" << m_decoderBusy
// << 0.001*(QDateTime::currentMSecsSinceEpoch()%60000);
if(m_decoderBusy) {
return; //Don't attempt decode if decoder already busy
}
@ -938,8 +939,8 @@ void MainWindow::decode() //decode()
m_saveFileName=m_saveDir + "/" + m_dateTime + ".qm";
}
qDebug() << "cc" << m_n60 << datcom2_.nhsym << m_nTx30a << m_nTx30b
<< 0.001*(QDateTime::currentMSecsSinceEpoch()%60000);
// qDebug() << "cc" << m_n60 << datcom2_.nhsym << m_nTx30a << m_nTx30b
// << 0.001*(QDateTime::currentMSecsSinceEpoch()%60000);
bool bSkipDecode=false;
//No need to call decoder for first half, if we transmitted in the first half:
@ -960,7 +961,7 @@ void MainWindow::decode() //decode()
memcpy(savecom_.revision, m_revision.toLatin1(), len2);
memcpy(savecom_.saveFileName, m_saveFileName.toLatin1(),len1);
qDebug() << "dd" << "starting q65c()" << 0.001*(QDateTime::currentMSecsSinceEpoch()%60000);
// qDebug() << "dd" << "starting q65c()" << 0.001*(QDateTime::currentMSecsSinceEpoch()%60000);
watcher3.setFuture(QtConcurrent::run (q65c_));
decodeBusy(true);
}