def setbufsize(size):
if size > <NUM_LIT>:<EOL><INDENT>raise ValueError("<STR_LIT>" % size)<EOL><DEDENT>if size < <NUM_LIT:5>:<EOL><INDENT>raise ValueError("<STR_LIT>" %size)<EOL><DEDENT>if size % <NUM_LIT:16> != <NUM_LIT:0>:<EOL><INDENT>raise ValueError("<STR_LIT>" %size)<EOL><DEDENT>pyvals = umath.geterrobj()<EOL>old = getbufsize()<EOL>pyvals[<NUM_LIT:0>] = size<EOL>umath.seterrobj(pyvals)<EOL>return old<EOL>
Set the size of the buffer used in ufuncs.

Parameters
----------
size : int
    Size of buffer.