Changeset 101065a in sasview
- Timestamp:
- Jan 6, 2012 11:38:28 AM (13 years ago)
- Branches:
- master, ESS_GUI, ESS_GUI_Docs, ESS_GUI_batch_fitting, ESS_GUI_bumps_abstraction, ESS_GUI_iss1116, ESS_GUI_iss879, ESS_GUI_iss959, ESS_GUI_opencl, ESS_GUI_ordering, ESS_GUI_sync_sascalc, costrafo411, magnetic_scatt, release-4.1.1, release-4.1.2, release-4.2.2, release_4.0.1, ticket-1009, ticket-1094-headless, ticket-1242-2d-resolution, ticket-1243, ticket-1249, ticket885, unittest-saveload
- Children:
- cd127d2
- Parents:
- 2b878d74
- Files:
-
- 5 added
- 7 deleted
- 8 edited
- 50 moved
Legend:
- Unmodified
- Added
- Removed
-
sansmodels/setup.py
r0ba3b08 r101065a 48 48 49 49 # Build the module name 50 srcdir = os.path.join("src", " c_extensions")50 srcdir = os.path.join("src", "include") 51 51 igordir = os.path.join("src", "libigor") 52 52 c_model_dir = os.path.join("src", "c_models") … … 61 61 c_wrapper_dir=wrapper_dir) 62 62 63 IGNORED_FILES = ["a.exe", 64 "__init__.py" 65 ".svn", 66 "lineparser.py", 67 "run.py", 68 "CGaussian.cpp", 69 "CLogNormal.cpp", 70 "CLorentzian.cpp", 71 "CSchulz.cpp", 72 "WrapperGenerator.py", 73 "wrapping.py" 74 ] 63 IGNORED_FILES = [".svn"] 75 64 if not os.name=='nt': 76 65 IGNORED_FILES.extend(["gamma_win.c","winFuncs.c"]) -
sansmodels/src/c_models/Hardsphere.cpp
r0ba3b08 r101065a 18 18 * sansmodels/src/libigor 19 19 * 20 * TODO: refactor so that we pull in the old sansmodels.c_extensions21 20 */ 22 21 -
sansmodels/src/c_models/c_models.cpp
r20d91bd r101065a 67 67 //void addCEllipticalCylinderModel(PyObject *module); 68 68 void addDisperser(PyObject *module); 69 void addCGaussian(PyObject *module);70 void addCLogNormal(PyObject *module);71 69 } 72 70 void addCLorentzian(PyObject *module); 73 71 void addCSchulz(PyObject *module); 72 void addCGaussian(PyObject *module); 73 void addCLogNormal(PyObject *module); 74 74 75 75 /** -
sansmodels/src/c_models/lorentzian.cpp
r82c11d3 r101065a 27 27 /** 28 28 * Function to evaluate 1D scattering function 29 29 * @param q: q-value 30 30 * @return: function value 31 31 */ … … 33 33 double delta2 = pow( (q-center()), 2); 34 34 return scale() / acos(-1.0) * 0.5*gamma() / 35 (delta2 + 0.25*gamma()*gamma());35 (delta2 + 0.25*gamma()*gamma()); 36 36 } 37 37 … … 48 48 /** 49 49 * Function to evaluate 2D scattering function 50 * @param pars: parameters of the cylinder51 50 * @param q: q-value 52 51 * @param phi: angle phi -
sansmodels/src/python_wrapper/WrapperGenerator.py
r642a025 r101065a 487 487 if len(sys.argv)>1: 488 488 print "Will look for file %s" % sys.argv[1] 489 #app = WrapperGenerator('../c_extensions/elliptical_cylinder.h')490 489 app = WrapperGenerator(sys.argv[1]) 491 490 else: -
sansmodels/src/python_wrapper/lineparser.py
r67424cd r101065a 192 192 # Read file 193 193 name= "sphere.h" 194 f = open("..\ c_extensions\core_shell.h",'r')194 f = open("..\include\core_shell.h",'r') 195 195 buf = f.read() 196 196 -
sansmodels/src/python_wrapper/wrapping.py
r642a025 r101065a 21 21 22 22 if __name__ == '__main__': 23 header_dir = os.path.join('..', ' c_extensions')23 header_dir = os.path.join('..', 'include') 24 24 generate_wrappers(header_dir, output_dir="../sans/models/", c_wrapper_dir='.') 25 25 -
setup.py
r20d91bd r101065a 212 212 213 213 # Sans models 214 srcdir = os.path.join("sansmodels", "src", "c_extensions")214 includedir = os.path.join("sansmodels", "src", "include") 215 215 igordir = os.path.join("sansmodels", "src", "libigor") 216 216 c_model_dir = os.path.join("sansmodels", "src", "c_models") … … 222 222 sys.path.append(os.path.join("sansmodels", "src", "python_wrapper")) 223 223 from wrapping import generate_wrappers 224 generate_wrappers(header_dir= srcdir,224 generate_wrappers(header_dir=includedir, 225 225 output_dir=os.path.join("sansmodels", "src", "sans", "models"), 226 226 c_wrapper_dir=wrapper_dir) 227 227 228 IGNORED_FILES = ["a.exe", 229 "__init__.py" 230 ".svn", 231 "lineparser.py", 232 "run.py", 233 "CGaussian.cpp", 234 "CLogNormal.cpp", 235 "WrapperGenerator.py", 236 "wrapping.py" 237 ] 238 228 IGNORED_FILES = [".svn"] 239 229 if not os.name=='nt': 240 230 IGNORED_FILES.extend(["gamma_win.c","winFuncs.c"]) … … 263 253 264 254 model_sources = [] 265 append_file(file_list=model_sources, dir_path=srcdir)266 255 append_file(file_list=model_sources, dir_path=igordir) 267 256 append_file(file_list=model_sources, dir_path=c_model_dir) … … 274 263 package_dir["sans"] = os.path.join("sansmodels", "src", "sans") 275 264 package_dir["sans.models"] = os.path.join("sansmodels", "src", "sans", "models") 276 package_dir["sans.models.sans_extension"] = srcdir265 package_dir["sans.models.sans_extension"] = includedir 277 266 278 267 package_data['sans.models'] = [os.path.join('media', "*")] … … 287 276 ext_modules.extend( [ Extension("sans.models.sans_extension.c_models", 288 277 sources=model_sources, 289 include_dirs=[igordir, srcdir,278 include_dirs=[igordir, includedir, 290 279 c_model_dir, numpy_incl_path], 291 280 ),
Note: See TracChangeset
for help on using the changeset viewer.