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’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Passing variables to task implementation in headless mode? #626

Open
SIHranova opened this issue Oct 17, 2023 · 3 comments
Open

Passing variables to task implementation in headless mode? #626

SIHranova opened this issue Oct 17, 2023 · 3 comments

Comments

@SIHranova
Copy link

SIHranova commented Oct 17, 2023

Hello, I hope I am posting in the right repo. I want to ask if it is possible to combine the concept of "experimental variables" with headless mode experiment batteries, because we want to pass information like task key mapping to the experiment implementation.

At the moment we have the following setup: participants register online, they are assigned a key mapping and then they get given the corresponding expfactory link to the task and a token (which I guess means we are running the tasks in headless mode?).
The problem is we have to have two separate implementations on different links for the same task, where the only difference is the key mapping of the task. What we would like to achieve is have only one implementation that gets told "this participants should have keymapping x" and then the experiment adapts accordingly and saves this information. Is this possible? I apologize if this is a doubling of a previous post.

@vsoch
Copy link
Member

vsoch commented Oct 17, 2023

If you are talking about headless and experiment variables I think you want expfactory/expfactory (not this repository) but no worries! Can you show me the command you are running to start your container?

@AlvaroAguilera
Copy link

Hi Vanessa!

Sia is a colleague of mine. These are the commands used to build and start the containers:

docker run --name build_$EXP -v /data/$EXP/exp-tasks:/data/ quay.io/vanessa/expfactory-builder build /data/exp01 /data/exp02

docker build --no-cache -t expfactory/experiments .

docker run --restart unless-stopped -v /data/$EXP/exp-results:/scif/data/expfactory -v /data/$EXP/exp-logs:/scif/logs -d --name $EXP expfactory/experiments --experiments exp01,exp02 --headless --no-randomize start

(some nginx-specific options omitted)

@vsoch
Copy link
Member

vsoch commented Oct 20, 2023

Gotcha. Have you played with https://expfactory.github.io/usage#participant-variables ? That would be the way to pass experiment and subject specific variables into the container, and would work in headless mode.

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

No branches or pull requests

3 participants