Comments (6)
Oh, and it occurs to me that settings.objects
enumerates a combination of elements and stages, so that would need to be cleaned up as well.
from psychtaskframework.
Determine the data structure for passing already-drawn elements- Determine the standard interface for element-drawing functions:
trialSettings, blockSettings
- Determine the terminology ("draw scripts" or "phase scripts"? "elements" or "objects"?) and amend
config
+ file & function names appropriately
from psychtaskframework.
Current next steps:
- Implement
offCenterByPx
indrawLotto
and a (more general)drawRef
so that tasks can stop endlessly duplicating that code. (Done in 3ad5aa4)
from psychtaskframework.
...okay. All of the ideas above are kinda bad. Here's where we're at.
Each phase draws many elements and one action. The draw scripts are fully defined by trial/block settings; they don't need to know about other drawn objects and it is the responsibility of the user to set them up correctly. The action is (in our current use cases) either to wait for some amount of time before moving onto the next phase, or to collect a response.
Actions are exactly what the callback logic was written for. The only problem: how do they know what phase they should be getting settings from? Some phaseSettings
struct, or some way to extract the relevant phaseSettings
out of blockSettings
, is necessary.
This might not be a bad time to emulate Stream in pre-set config objects and set up a phaseConfig
function that produces a validated phaseConfig
struct. This struct has to contain (at least) duration, cell array of draw function handles, and an action function handle.
from psychtaskframework.
One way to get around the "what phase am I getting settings from?" problem is to create phaseSettings
right before the action callback in the phase script. The phase script knows what phase it is and what durations to look for. This can be generalized, but at the cost of either (a) exporting the callback logic to separate XYZ_runTrial
files, or (b) defining the actions in the config somehow.
See #26 for extended discussion.
from psychtaskframework.
There's pie-in-the-sky work to be done on #26, but draw elements, actions, and phases have been separated fairly cleanly. This issue will close as soon as I merge 37_phase_and_draw_scripts
.
from psychtaskframework.
Related Issues (20)
- Reversed probability level reporting HOT 4
- Export cannot handle subjects with unfinished blocks
- Task, block, phase as Matlab objects
- Separate out trial generation from generateBlocks HOT 6
- Save the current commit/version in text file, DataObject HOT 2
- README in each task folder HOT 8
- Halt the block after n non-responses HOT 2
- Sphinx code documentation HOT 4
- Fix lotto positioning HOT 13
- Complete coverage of tasks with visual tests
- Unit testing for PTF
- Create an easy, complete setup
- Task: Uncertain reference R&A
- GStreamer text rendering on Windows breaks some text in HLFF/HF
- Division of blocks across the SODM beneficiary condition is wrong
- Get Sikuli + Robot Framework to run in a virtual machine
- Create a conflict task
- Create a quickstart
- Mark deprecations
- Task: Reversal learning
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from psychtaskframework.