From e33c6fab8b8dd8adb3d71af8517dfe45ba264cf7 Mon Sep 17 00:00:00 2001 From: Anthony LaTorre Date: Wed, 17 Aug 2011 10:36:22 -0400 Subject: import chroma modules from subpackages with import chroma.module_name --- src/__init__.py | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) (limited to 'src/__init__.py') diff --git a/src/__init__.py b/src/__init__.py index 865d612..f2f5215 100644 --- a/src/__init__.py +++ b/src/__init__.py @@ -1,6 +1,7 @@ -import os +from os.path import dirname -dir = os.path.split(os.path.realpath(__file__))[0] +with open(dirname(__file__) + '/kernel.cu') as f: + kernel = f.read() -kernel = open(dir + '/kernel.cu').read() -daq = open(dir + '/daq.cu').read() +with open(dirname(__file__) + '/daq.cu') as f: + daq = f.read() -- cgit