-
Notifications
You must be signed in to change notification settings - Fork 25
/
impl-no-duals.rkt
24 lines (20 loc) · 1004 Bytes
/
impl-no-duals.rkt
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
#lang racket
(require (for-syntax "impl-loader.rkt"))
;;--------------------------------
;; Define an implementation loader
;;--------------------------------
(define-syntax load-tensors
(λ (x)
(printf "Tensor implementation (no-duals): ~s~%" (tensor-implementation))
#`(begin
#,(case (tensor-implementation)
((learner) #'(require "learner/no-duals.rkt"))
((flat-tensors) #'(require "flat-tensors/no-duals.rkt"))
((uniform-tensors) #'(require "uniform-tensors/no-duals.rkt"))
((nested-tensors) #'(require "nested-tensors/no-duals.rkt")))
#,(case (tensor-implementation)
((learner) #'(provide (all-from-out "learner/no-duals.rkt")))
((flat-tensors) #'(provide (all-from-out "flat-tensors/no-duals.rkt")))
((uniform-tensors) #'(provide (all-from-out "uniform-tensors/no-duals.rkt")))
((nested-tensors) #'(provide (all-from-out "nested-tensors/no-duals.rkt")))))))
(load-tensors)