"docs/git@developer.sourcefind.cn:renzhc/diffusers_dcu.git" did not exist on "8cc528c5e75aa7d66ed17bfd086d194a9fe5563c"
Commit 025824d2 authored by Max Ryabinin's avatar Max Ryabinin
Browse files

Reduce diff

parent 575aa698
......@@ -41,6 +41,14 @@ void quantize(float *code, float *A, unsigned char *out, int n)
CUDA_CHECK_RETURN(cudaPeekAtLastError());
}
void dequantize(float *code, unsigned char *A, float *out, int n)
{
int blocks = n/1024;
blocks = n % 1024 == 0 ? blocks : blocks + 1;
kDequantize<<<blocks, 1024>>>(code, A, out, n);
CUDA_CHECK_RETURN(cudaPeekAtLastError());
}
template <typename T, int STOCHASTIC> void quantizeBlockwise(float * code, T *A, float *absmax, unsigned char *out, float *rand, int rand_offset, const int n)
{
int blocks = n/4096;
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment