Welcome!

Sign in with your CogSci, Facebook, Google, or Twitter account.

Or register to create a new account.

We'll use your information only for signing in to this forum.

Supported by

[solved] can launch *.opensesame file with its engine (Non GUI part)?

dyedye Posts: 5
edited January 2014 in OpenSesame

I am a new user to opensesame and very interested in its powerful GUI-based experiment design style.

I have the following question:
For example, we design many experiments with openSesame GUI environment. After that we would like to play these experiment files(*.opensesame) without using openSesame GUI environment that was used to create them. Just like in E-Prime, E-studio is used to create paradigms, you can launch paradigms with E-run engine. Is there a similiar engine in openSesame?

Thanks,

Ye

Comments

  • sebastiaansebastiaan Posts: 2,812
    edited 9:55AM

    Hi Dye,

    Thank you for your interest in OpenSesame!

    OpenSesame includes a program called opensesamerun that does what you're looking for. If you're on Windows, it's located as opensesamerun.exe in the OpenSesame folder.

    There's not really any benefit over using the GUI, though, so I don't personally use it much. But if you prefer opensesamerun over the GUI, it's there!

    Kindest regards,
    Sebastiaan

    There's much bigger issues in the world, I know. But I first have to take care of the world I know.
    cogsci.nl/smathot

  • dyedye Posts: 5
    edited 9:55AM

    Sebastiaan,
    Thank your help. What I am planning to do is to integrate the opensesamerun.exe with my own application to launch existed opensesame paradigms on the fly(i.e. users can select any available opensesame paradigm at runtime via my own GUI), and somehow let my application to communicate with and control the different states of opensesame paradigms while it is played in openSesamerun or its play engine. So I would like to setup an interface between my application and openSesame by socket/tcp.

    thanks,

    Ye

  • dyedye Posts: 5
    edited 9:55AM

    Do you have any suggestion/direction on my above plan?
    thanks.

  • sebastiaansebastiaan Posts: 2,812
    edited 9:55AM

    Hi Ye,

    Right, I see. Cool idea. The two easiest way to do this are probably:

    Using opensesamerun

    Have your own software call opensesamerun and specify all relevant parameters on the command line (see opensesamerun.exe --help for a list of options).

    Use OpenSesame as a Python module

    You could also write a Python script to listen for incoming connections, run experiments, etc. All functionality is available through the libopensesame module. You can find an example of how to run an experiment this way in this discussion. This approach is much more flexible, of course, so it seems like the way to go in your case. The downside is that you will need a full Python environment on each system, because you can't use the binary packages.

    Hope this helps!

    Regards,
    Sebastiaan

    There's much bigger issues in the world, I know. But I first have to take care of the world I know.
    cogsci.nl/smathot

  • dyedye Posts: 5
    edited 9:55AM

    Hello Sebastiaan,

    Is it possibe to rewrite opensesamerun with C/C++? so that we don't need to install a full Python evenironment at all.

    Thanks, and

    Best regards,

    Ye

  • sebastiaansebastiaan Posts: 2,812
    edited 9:55AM

    Hi Ye,

    No, I'm afraid not. OpenSesame is pure Python. What you could do is develop your own client, perhaps based on OpenSesamerun, and build an .exe file using py2exe. This essentially means that you will get a standalone package that includes a full Python environment, which is also how the regular OpenSesame packages work. This package can then be distributed without requiring users to install all kinds of stuff.

    On GitHub you will find a py2exe setup script in the win32-resources folder:
    link

    Good luck!

    Sebastiaan

    There's much bigger issues in the world, I know. But I first have to take care of the world I know.
    cogsci.nl/smathot

  • dyedye Posts: 5
    edited 9:55AM

    Hi Sebastiaan,

    Can we use OpenSesame in a commercial product?

    thanks,

    Ye

  • sebastiaansebastiaan Posts: 2,812
    edited 9:55AM

    Hi Dye,

    OpenSesame is released under the GNU General Public License. This allows for particular uses in commercial products, but there are many restrictions. Notably, you can use OpenSesame as long as it's unmodified and a clearly separable module. So, for example, you would be allowed to call opensesamerun from an external program, but not to modify the code of opensesamerun and distribute it in a commercial product. So basically, if you decide to use OpenSesame in a commercial product, please make sure that the GPL is not violated. For more information on the GPL, see here: http://www.gnu.org/licenses/gpl-faq.html

    Alternatively, you could explain exactly what you want to do and I (as the developer) could provide explicit permission. I must say that I would only be inclined to do this if there is a really good reason, because I strongly prefer the open source route!

    Kindest regards,
    Sebastiaan

    There's much bigger issues in the world, I know. But I first have to take care of the world I know.
    cogsci.nl/smathot

Sign In or Register to comment.