Did I find the right examples for you? yes no      Crawl my project      Python Jobs

All Samples(26)  |  Call(10)  |  Derive(0)  |  Import(16)

src/p/a/parakeet-0.23.2/parakeet/transforms/flattening.py   parakeet(Download)
                       Int64, PtrT, ptr_type, ClosureT, FnT, StructT, 
                       TypeValueT)
from ..syntax import (Var, Tuple, 
                      Index, TypedFn, Return, Stmt, Assign, Alloc,  
                      ParFor, PrimCall, If, While, ForLoop, Call, Expr, 
  def flatten_Alloc(self, expr):
    count_exprs = self.flatten_expr(expr.count)
    assert len(count_exprs) == 1
    return Alloc(count = count_exprs[0], elt_type = expr.elt_type, type = expr.type)
 
    for dim in shape_elts:
      nelts = self.mul(nelts, dim)
    ptr = Alloc(elt_type = expr.elt_type, count = nelts, type = ptr_type(expr.elt_type))
    stride_elts = self.strides_from_shape_elts(shape_elts)
    return (ptr,) + tuple(shape_elts) + tuple(stride_elts) + (self.int(0), nelts)

src/p/a/parakeet-HEAD/parakeet/transforms/flattening.py   parakeet(Download)
                       Int64, PtrT, ptr_type, ClosureT, FnT, StructT, 
                       TypeValueT)
from ..syntax import (Var, Tuple, 
                      Index, TypedFn, Return, Stmt, Assign, Alloc,  
                      ParFor, PrimCall, If, While, ForLoop, Call, Expr, 
  def flatten_Alloc(self, expr):
    count_exprs = self.flatten_expr(expr.count)
    assert len(count_exprs) == 1
    return Alloc(count = count_exprs[0], elt_type = expr.elt_type, type = expr.type)
 
    for dim in shape_elts:
      nelts = self.mul(nelts, dim)
    ptr = Alloc(elt_type = expr.elt_type, count = nelts, type = ptr_type(expr.elt_type))
    stride_elts = self.strides_from_shape_elts(shape_elts)
    return (ptr,) + tuple(shape_elts) + tuple(stride_elts) + (self.int(0), nelts)

src/p/a/parakeet-0.23.2/parakeet/transforms/clone_function.py   parakeet(Download)
from .. import names 
from .. syntax import (TypedFn, Var, Const, Attribute, Index, PrimCall, 
                       If, Assign, While, ExprStmt, Return, ForLoop, ParFor,  
                       Slice, Struct, Tuple, TupleProj, Cast, Alloc, Closure, 
                       Map, Reduce, Scan, IndexMap, IndexReduce, IndexScan, 
 
    elif c is Alloc:
      return Alloc(count = self.transform_expr(expr.count), 
                   elt_type = expr.elt_type)
    elif c is Map:

src/p/a/parakeet-HEAD/parakeet/transforms/clone_function.py   parakeet(Download)
from .. import names 
from .. syntax import (TypedFn, Var, Const, Attribute, Index, PrimCall, 
                       If, Assign, While, ExprStmt, Return, ForLoop, ParFor,  
                       Slice, Struct, Tuple, TupleProj, Cast, Alloc, Closure, 
                       Map, Reduce, Scan, IndexMap, IndexReduce, IndexScan, 
 
    elif c is Alloc:
      return Alloc(count = self.transform_expr(expr.count), 
                   elt_type = expr.elt_type)
    elif c is Map:

src/p/a/parakeet-0.23.2/parakeet/transforms/lower_structs.py   parakeet(Download)
from .. ndtypes import (ScalarT, ArrayT, make_array_type, TupleT, 
                        Int32, Int64,  ptr_type, PtrT, closure_type)  
from .. syntax import Struct, Assign, Const, Index, Attribute, Var, Tuple, Alloc  
from .. syntax.helpers import const_int, const_tuple, zero
from transform import Transform
 
    ptr_t = ptr_type(elt_t)
    alloc = Alloc(elt_t, const_int(n), type = ptr_t)
    ptr_var = self.assign_name(alloc, "data")
 

src/p/a/parakeet-HEAD/parakeet/transforms/lower_structs.py   parakeet(Download)
from .. ndtypes import (ScalarT, ArrayT, make_array_type, TupleT, 
                        Int32, Int64,  ptr_type, PtrT, closure_type)  
from .. syntax import Struct, Assign, Const, Index, Attribute, Var, Tuple, Alloc  
from .. syntax.helpers import const_int, const_tuple, zero
from transform import Transform
 
    ptr_t = ptr_type(elt_t)
    alloc = Alloc(elt_t, const_int(n), type = ptr_t)
    ptr_var = self.assign_name(alloc, "data")
 

src/p/a/parakeet-0.23.2/parakeet/transforms/lower_array_operators.py   parakeet(Download)
from ..builder import build_fn
from ..syntax import  Alloc,  Index, ArrayView, Const, Transpose, Ravel 
from ..syntax.helpers import zero_i64, one_i64, const_int, const_tuple, true, false   
from ..ndtypes import (ScalarT, PtrT, TupleT, ArrayT, ptr_type, Int64)
 
 
    ptr_t = ptr_type(elt_t)
    alloc = Alloc(elt_t, const_int(n), type = ptr_t)
    ptr_var = self.assign_name(alloc, "data")
    array = self.array_view(ptr_var, 

src/p/a/parakeet-HEAD/parakeet/transforms/lower_array_operators.py   parakeet(Download)
from ..builder import build_fn
from ..syntax import  Alloc,  Index, ArrayView, Const, Transpose, Ravel 
from ..syntax.helpers import zero_i64, one_i64, const_int, const_tuple, true, false   
from ..ndtypes import (ScalarT, PtrT, TupleT, ArrayT, ptr_type, Int64)
 
 
    ptr_t = ptr_type(elt_t)
    alloc = Alloc(elt_t, const_int(n), type = ptr_t)
    ptr_var = self.assign_name(alloc, "data")
    array = self.array_view(ptr_var, 

src/p/a/parakeet-0.23.2/parakeet/analysis/syntax_visitor.py   parakeet(Download)
from .. syntax import (Expr, Assign, ExprStmt, ForLoop, If, Return, While, Comment, ParFor, 
                       TypedFn, UntypedFn,  Closure, ClosureElt, Select,  
                       Attribute, Const, Index, PrimCall, Tuple, Var, 
                       Alloc, Array, Call, Struct, Shape, Strides, Range, Ravel, Transpose,
                       AllocArray, ArrayView, Cast, Slice, TupleProj, TypeValue,  

src/p/a/parakeet-HEAD/parakeet/analysis/syntax_visitor.py   parakeet(Download)
from .. syntax import (Expr, Assign, ExprStmt, ForLoop, If, Return, While, Comment, ParFor, 
                       TypedFn, UntypedFn,  Closure, ClosureElt, Select,  
                       Attribute, Const, Index, PrimCall, Tuple, Var, 
                       Alloc, Array, Call, Struct, Shape, Strides, Range, Ravel, Transpose,
                       AllocArray, ArrayView, Cast, Slice, TupleProj, TypeValue,  

  1 | 2  Next