You can subscribe to this list here.
2005 
_{Jan}

_{Feb}

_{Mar}

_{Apr}

_{May}

_{Jun}

_{Jul}

_{Aug}
(1) 
_{Sep}

_{Oct}
(11) 
_{Nov}
(184) 
_{Dec}
(182) 

2006 
_{Jan}
(224) 
_{Feb}
(404) 
_{Mar}
(244) 
_{Apr}
(232) 
_{May}
(162) 
_{Jun}
(193) 
_{Jul}
(174) 
_{Aug}
(161) 
_{Sep}
(170) 
_{Oct}
(283) 
_{Nov}
(310) 
_{Dec}
(130) 
2007 
_{Jan}
(210) 
_{Feb}
(129) 
_{Mar}
(174) 
_{Apr}
(246) 
_{May}
(269) 
_{Jun}
(212) 
_{Jul}
(229) 
_{Aug}
(202) 
_{Sep}
(190) 
_{Oct}
(194) 
_{Nov}
(172) 
_{Dec}
(128) 
2008 
_{Jan}
(343) 
_{Feb}
(137) 
_{Mar}
(186) 
_{Apr}
(266) 
_{May}
(156) 
_{Jun}
(147) 
_{Jul}
(140) 
_{Aug}
(78) 
_{Sep}
(128) 
_{Oct}
(126) 
_{Nov}
(100) 
_{Dec}
(106) 
2009 
_{Jan}
(152) 
_{Feb}
(165) 
_{Mar}
(209) 
_{Apr}
(166) 
_{May}
(97) 
_{Jun}
(152) 
_{Jul}
(159) 
_{Aug}
(196) 
_{Sep}
(151) 
_{Oct}
(107) 
_{Nov}
(128) 
_{Dec}
(64) 
2010 
_{Jan}
(105) 
_{Feb}
(77) 
_{Mar}
(129) 
_{Apr}
(151) 
_{May}
(126) 
_{Jun}
(97) 
_{Jul}
(86) 
_{Aug}
(99) 
_{Sep}
(64) 
_{Oct}
(88) 
_{Nov}
(59) 
_{Dec}
(91) 
2011 
_{Jan}
(159) 
_{Feb}
(111) 
_{Mar}
(153) 
_{Apr}
(114) 
_{May}
(88) 
_{Jun}
(201) 
_{Jul}
(158) 
_{Aug}
(124) 
_{Sep}
(101) 
_{Oct}
(149) 
_{Nov}
(160) 
_{Dec}
(68) 
2012 
_{Jan}
(74) 
_{Feb}
(68) 
_{Mar}
(121) 
_{Apr}
(92) 
_{May}
(172) 
_{Jun}
(100) 
_{Jul}
(85) 
_{Aug}
(65) 
_{Sep}
(74) 
_{Oct}
(105) 
_{Nov}
(76) 
_{Dec}
(21) 
2013 
_{Jan}
(101) 
_{Feb}
(57) 
_{Mar}
(76) 
_{Apr}
(35) 
_{May}
(43) 
_{Jun}
(50) 
_{Jul}
(32) 
_{Aug}
(50) 
_{Sep}
(33) 
_{Oct}
(58) 
_{Nov}
(26) 
_{Dec}
(49) 
2014 
_{Jan}
(46) 
_{Feb}
(49) 
_{Mar}
(54) 
_{Apr}
(33) 
_{May}
(46) 
_{Jun}
(57) 
_{Jul}
(34) 
_{Aug}
(36) 
_{Sep}
(69) 
_{Oct}
(37) 
_{Nov}
(27) 
_{Dec}
(57) 
2015 
_{Jan}
(25) 
_{Feb}
(52) 
_{Mar}
(97) 
_{Apr}
(41) 
_{May}
(44) 
_{Jun}
(36) 
_{Jul}
(27) 
_{Aug}
(33) 
_{Sep}
(29) 
_{Oct}
(45) 
_{Nov}
(23) 
_{Dec}
(23) 
2016 
_{Jan}
(6) 
_{Feb}
(31) 
_{Mar}
(17) 
_{Apr}
(41) 
_{May}
(31) 
_{Jun}
(51) 
_{Jul}
(20) 
_{Aug}
(36) 
_{Sep}
(69) 
_{Oct}
(55) 
_{Nov}
(29) 
_{Dec}
(17) 
2017 
_{Jan}
(25) 
_{Feb}
(22) 
_{Mar}
(29) 
_{Apr}
(18) 
_{May}
(30) 
_{Jun}
(13) 
_{Jul}
(22) 
_{Aug}
(12) 
_{Sep}
(20) 
_{Oct}
(60) 
_{Nov}
(32) 
_{Dec}

S  M  T  W  T  F  S 




1

2

3
(1) 
4

5

6

7
(1) 
8

9
(1) 
10
(2) 
11

12
(3) 
13
(5) 
14
(5) 
15

16
(2) 
17
(2) 
18
(1) 
19

20

21

22
(4) 
23
(7) 
24
(1) 
25

26

27
(2) 
28
(1) 
29
(1) 
30
(1) 
31
(3) 

From: Kevin Kunzmann <kevinkunzmann@gm...>  20130531 18:00:20

Hi, I am new to swig and wanted to make the function agf_calc_pdf from the following src/agf_pdf.cxx file available in python: #include "math.h" #define _USE_MATH_DEFINES struct agf_diag_param { unsigned int nd; //number of squarings float f; //ratio of min. weight to max. float W; //total weight }; template <class real, class index> real metric2(real *v1, real *v2, index m) { real d; real diff; d = 0; for (index i = 0; i < m; i++) { diff = v2[i]  v1[i]; d += diff * diff; } return d; } template <class real, class index> unsigned int agf_calc_w( real *d2, //distances squared index k, //number of distances real Wc, //objective total weight real var[2], //initial filter width real *weight, //returned weights real &var_f) //returned final filter variance { unsigned int nd; //number of squarings of the weights real tw_old; //previous value of the total weight real tw; //current value of the total weight real wtint; //for interpolation of final weights //calculate the weights: for (index i = 0; i < k; i++) weight[i] = exp( d2[i] / var[1] / 2); //repeatedly square the weights until the total is less than the threshold: tw = 0; for (index i = 0; i < k; i++) tw += weight[i]; nd = 0; do { tw_old = tw; tw = 0; for (index i = 0; i < k; i++) { weight[i] *= weight[i]; tw += weight[i]; } nd++; } while (tw > Wc && tw < tw_old); //interpolate between the current and previous weight: wtint = (log(tw_old)  log(Wc)) / (log(tw_old)  log(tw)) / 2 + 0.5; //calculate the final filter width: var_f = var[1] / (1 << nd) / wtint; tw = 0; for (index i = 0; i < k; i++) { weight[i] = exp(d2[i] / var_f / 2); } //return the number of iterations as a diagnostic parameter: return nd; } template <class real, class index> real agf_calc_pdf( real **mat, real *vec, index D, index n, real var[2], real Wc ) { real *d2; //the distances (squared) real var_f; //final value of the filter width (as variance) real tw; //total weight real *weight; //the current value for the weights real n1, norm; //normalisation coeff. real pdf; //final calculated value of pdf agf_diag_param* diag_param; // dummy output buffer //first we calculate all the distances: d2 = new real[n]; for (index i = 0; i < n; i++) { d2[i] = metric2(vec, mat[i], D); } //calculate the weights using the central "engine": weight = new real[n]; diag_param>nd = agf_calc_w(d2, n, Wc, var, weight, var_f); tw = 0; for (index i = 0; i < n; i++) tw += weight[i]; //use the final filter width to normalize the pdf: n1 = sqrt( var_f * M_PI *2 ); norm = 1; for (index i = 0; i < D; i++) norm *= n1; pdf = tw / norm /n; //set the diagnostic parameters: diag_param>W = tw; delete [] d2; delete [] weight; return pdf; } I wrote an interface file agf.i for the template function: %module agf %{ struct agf_diag_param { unsigned int nd; //number of squarings float f; //ratio of min. weight to max. float W; //total weight }; template <class real, class index> real metric2(real *v1, real *v2, index m); template <class real, class index> unsigned int agf_calc_w( real *d2, //distances squared index k, //number of distances real Wc, //objective total weight real var[2], //initial filter width real *weight, //returned weights real &var_f); //returned final filter variance template <class real, class index> real agf_calc_pdf( real **mat, real *vec, index D, index n, real var[2], real Wc ); %} template <class real, class index> real agf_calc_pdf( real **mat, real *vec, index D, index n, real var[2], real Wc ); %template(pdf) agf_calc_pdf<double, int>; and finally a setup.py: #!/usr/bin/env python from distutils.core import setup, Extension module = Extension('_agf', sources=['agf_wrap.cxx', 'src/agf_pdf.cxx'], language="c++" ) setup (name = 'agf', ext_modules = [module], py_modules = ["agf"] ) Then I invoked swig via: swig c++ python agf.i which runs without problems. python setup.py build_ext inplace gives some warnings about unused variables, but nothing else. I then import the generated agf.py and get an import error "ImportError: ./_agf.so: undefined symbol: _Z12agf_calc_pdfIdiET_PPS0_S1_T0_S3_S1_S0_" any ideas? yours, Kevin 
From: Klaus Kaempf <kkaempf@su...>  20130531 08:35:43

* Klaus Kaempf <kkaempf@...> [May 31. 2013 10:27]: > > > > SimpleITKRUBY_wrap.cxx: In function ‘VALUE SWIG_From_std_complex_Sl_float_Sg_(const std::complex<float>&)’: > > SimpleITKRUBY_wrap.cxx:9979: error: ‘rb_complex_new’ was not declared in this scope > > Hmm, rb_complex_new was introduced in Ruby 1.9. Ruby 1.8 does not have > this as an internal type. Looking further, SWIG does define its own version of rb_complex_new() if its not provided by Ruby. Why isn't it picked up in your case ? Can you come up with a minimal test case ? Klaus  SUSE LINUX Products GmbH, GF: Jeff Hawn, Jennifer Guild, Felix Imendörffer, HRB 16746 (AG Nürnberg) Maxfeldstraße 5, 90409 Nürnberg, Germany 
From: Klaus Kaempf <kkaempf@su...>  20130531 08:25:22

* Bradley Lowekamp <blowekamp@...> [May 30. 2013 17:17]: > Hello, > > I am trying to upgrade my project to Swig 2.0.10 and I am getting the following compilation error: > > SimpleITKRUBY_wrap.cxx: In function ‘VALUE SWIG_From_std_complex_Sl_float_Sg_(const std::complex<float>&)’: > SimpleITKRUBY_wrap.cxx:9979: error: ‘rb_complex_new’ was not declared in this scope Hmm, rb_complex_new was introduced in Ruby 1.9. Ruby 1.8 does not have this as an internal type. > > /*@SWIG@*/ c) > { > VALUE re = rb_float_new(std::real(c)); > VALUE im = rb_float_new(std::imag(c)); > return rb_complex_new(re, im); > } > > > This is being built on a Redhat 6 system against the system support version of Ruby: Apparently you found a regression bug in SWIG which isn't covered by the current test suite. I have just created https://github.com/swig/swig/issues/52 to track this. Klaus  SUSE LINUX Products GmbH, GF: Jeff Hawn, Jennifer Guild, Felix Imendörffer, HRB 16746 (AG Nürnberg) Maxfeldstraße 5, 90409 Nürnberg, Germany 