Ignore:
Timestamp:
Jun 26, 2008 12:26:52 PM (16 years ago)
Author:
nanang
Message:

Ticket #543: Updated PESQ test, sound device used only by one side to avoid contention

File:
1 edited

Legend:

Unmodified
Added
Removed
  • pjproject/trunk/pjsip-apps/src/test-pjsua/mod_pesq.py

    r2052 r2057  
    2626# PESQ_THRESHOLD specifies the minimum acceptable PESQ MOS value, so test can be declared successful 
    2727PESQ = "tools/pesq.exe" 
    28 PESQ_THRESHOLD = 1.0 
     28PESQ_THRESHOLD = 3.0 
    2929 
    3030# UserData 
     
    3939# Test body function 
    4040def test_func(t, user_data): 
     41 
     42        if len(t.process) == 0: 
     43                return 
     44 
    4145        ua1 = t.process[0] 
    4246        ua2 = t.process[1] 
     
    9498 
    9599        # Parse ouput 
    96         mo_pesq_out = re.compile("Prediction\s+:\s+PESQ_MOS\s+=\s+(.+)\s*").search(pesq_out[0]) 
     100        mo_pesq_out = re.compile("Prediction[^=]+=\s+([\d\.]+)\s*").search(pesq_out[0]) 
    97101        if (mo_pesq_out == None): 
    98102                raise TestError("Failed to fetch PESQ result") 
     
    101105        pesq_res = mo_pesq_out.group(1) 
    102106        if (float(pesq_res) >= PESQ_THRESHOLD): 
    103                 endpt.trace("Success, PESQ result=" + pesq_res) 
     107                endpt.trace("Success, PESQ result = " + pesq_res) 
    104108        else: 
    105                 endpt.trace("Failed, PESQ result=" + pesq_res) 
     109                endpt.trace("Failed, PESQ result = " + pesq_res) 
    106110                raise TestError("WAV seems to be degraded badly") 
    107111 
Note: See TracChangeset for help on using the changeset viewer.