Remove float64 (#1101)

* Refactor: Remove float64

* Refactor: Remove unused imports

* Refactor: Remove float64

* Refactor: Remove float64

* Refactor: Exclude float64 onnx backend

* Add: Skip jacobian and gradcheck tests;
This commit is contained in:
Reza Rezvan
2023-07-04 17:40:51 +02:00
committed by GitHub
parent b4ce23e4b8
commit 535224ac20
10 changed files with 9 additions and 31 deletions

View File

@@ -3,7 +3,7 @@ import pathlib
import numpy as np
import pyopencl as cl # type: ignore
from typing import Optional, List
from tinygrad.helpers import DEBUG, getenv, prod, ImageDType, OSX, dtypes, fromimport
from tinygrad.helpers import DEBUG, getenv, prod, ImageDType, OSX, fromimport
from tinygrad.ops import Compiled
from tinygrad.runtime.lib import RawBufferCopyInOut
from tinygrad.codegen.cstyle import CStyleCodegen, CStyleLanguage
@@ -30,7 +30,6 @@ CL = _CL()
class CLBuffer(RawBufferCopyInOut):
def __init__(self, size, dtype, device='0'):
assert not OSX or dtype != dtypes.float64, "OpenCL on Mac doesn't support float64"
if isinstance(dtype, ImageDType):
fmt = cl.ImageFormat(cl.channel_order.RGBA, {2: cl.channel_type.HALF_FLOAT, 4: cl.channel_type.FLOAT}[dtype.itemsize])
buf = cl.Image(CL.cl_ctx, cl.mem_flags.READ_WRITE, fmt, shape=(dtype.shape[1], dtype.shape[0]))