inference.rst: fix doctests

6 jobs for master in 208 minutes and 20 seconds (queued for 2 seconds)
Status Job ID Name Coverage
  Test
passed #2231
amd64
job_clang_amd64

02:57:57

passed #2235
amd64
job_clang_amd64_nosh

02:50:52

passed #2233
amd64
job_clang_py2_amd64

02:53:05

passed #2230
amd64
job_gcc_amd64

02:18:34

passed #2234
amd64
job_gcc_amd64_nosh

02:11:23

passed #2232
amd64
job_gcc_py2_amd64

02:14:46