Q:

How to get 3 float numbers randomly with the step of 0.5 between 5.0 and 9.0 using Numpy? 

How to get 3 float numbers randomly with the step of 0.5 between 5.0 and 9.0 using Numpy? 
I tried as follows:
np.random.uniform(5.0,9.0) 

But it does not include the 'step' parameter. 
EDIT:
Python random.randrange provides the way of using 'step'.  But it works only for integers. 
random.randrange(start, stop[, step])

I want to get 3 such numbers:
The expected result should be as follows:
ans = [5.5, 6.0, 8.5]

A:

Just divide...
val = np.random.randint(2*5,2*9)/2. 

randint returns a uniformly distributed integer in the range [10,18) and then you just do a float division by 2.  This has the benefit of being fairly fast:
In [120]: %timeit np.random.randint(2*5,2*9)/2. 
1000000 loops, best of 3: 329 ns per loop

In [121]: %timeit 0.5 * ceil(2.0 * np.random.uniform(5.0, 9.0))
100000 loops, best of 3: 4.61 µs per loop

To make this a bit more generic:
def rand_with_step(low,high,step,count=1,bias=False):
    n = 1/step
    if count > 1:
        val = np.random.randint(low*n,high*n,count)*step
    else:
        val= np.random.randint(low*n,high*n)*step

    if bias:
        bias = ceil(low/step)*step - low
    else:
        bias = 0
    return val - bias

here the bias flag determines whether the steps are counted starting at the value of low. 
For example:
In [190]: rand_with_step(5,9,0.11,1,True)
Out[190]: 7.31

Which should be correct as ( 7.31 - 5 )/0.11 = 29 a full multiple of the step. 
It's worth noting that this method is faster than np.random.choice even with a pre-calculated pool of numbers to draw from (although it is not clear to me why). 
In [343]: x = np.arange(5, 9, 0.5)

In [344]: %timeit np.random.choice(x,size=3)
10000 loops, best of 3: 29.7 µs per loop

In [345]: %timeit rand_with_step(5,9,0.5,3,True)
10000 loops, best of 3: 25.3 µs per loop

A:

I'd probably use something like @ebarr's answer, but here's an alternative. 
Create the desired range using np.arange, and then select from that array using np.random.choice:
In [134]: np.random.choice(np.arange(5, 9, 0.5), size=3)
Out[134]: array([ 7. ,   8.5,  7.5])

Note that if you use arange like this, 9 is not included in the possible output.   If you want to include the upper limit, you could use np.arange(5, 9.25, 0.5), or more generally, np.arange(start, stop+0.5*step, step). 
This is not very efficient if the desired range is large and you only select a few values.   If you are going to repeatedly select from the same set of numbers, you can define the possible values once and reuse that variable:
In [135]: values = np.arange(5, 9, 0.5)

In [136]: np.random.choice(values, size=3)
Out[136]: array([ 6.5,  5. ,   6. ]) 

In [137]: np.random.choice(values, size=5)
Out[137]: array([ 6. ,   8. ,   6. ,   7.5,  8. ])