Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We鈥檒l occasionally send you account related emails.

Already on GitHub? Sign in to your account

add SWIG interface for tags #3332

Closed
wants to merge 1 commit into from

Conversation

sanuj
Copy link
Contributor

@sanuj sanuj commented Jul 4, 2016

A few questions:

  • How to test this:question: Shall I add meta-language code for testing:question:
  • Where to include MockObject in SWIG:question: This will be required for testing.
  • Commented out SG_INSTA are abstract templates in shogun. @lisitsyn wanted to discuss something about these with @karlnapf or @vigsterkr.

SG_INSTA stands for shogun instantiate. Can change the name if someone proposes a better one. 馃槃

This code works in Python. Here is some old working example but it won't work with latest changes like registering arbitrary parameters is not allowed now. Will update this example as soon as I know where to put MockObject in SWIG.

@karlnapf
Copy link
Member

karlnapf commented Jul 4, 2016

You can add meta language examples for testing, yes.
If you find that something is incomplete, let me know.
Pls do this in the way I described in #3328 i.e. create a file that is a test and an api illustration for tags at the same time

@karlnapf
Copy link
Member

karlnapf commented Jul 4, 2016

No idea about the mock object .... @lisitsyn ?
I guess we could hack cmake to allow for an additional folder that is exposed to SWIG
OR, you actually change on class in this PR to use the new framework....

@karlnapf
Copy link
Member

karlnapf commented Jul 5, 2016

The classes in there are way to specific. I dont understand at all why this is done? Can you explain a bit?

@sanuj sanuj mentioned this pull request Jul 6, 2016
@sanuj
Copy link
Contributor Author

sanuj commented Jul 6, 2016

@karlnapf These are abstract classes in shogun i.e. they have a pure virtual function. Now the plan has changed. @lisitsyn and I decided to create a new jinja file which will have SWIG interface for set/get/has/Tag and this file will be included in SGBase.i. The jinja file will read the names (X) of classes from shogun-base.txt and generate code for setX() / getX() / hasX() / TagX in SWIG. Initially we will have 3-4 classes in shogun-base.txt and we can keep adding on classes later. shogun-base.txt will have list of classes that we want to keep in base shogun.

@sanuj
Copy link
Contributor Author

sanuj commented Jul 9, 2016

馃憖 See add swig for tags using Jinja #3357.

@sanuj sanuj closed this Jul 9, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants