Image preloading - experiment failed to load #2948
Answered
by
synapticlee
synapticlee
asked this question in
Q&A
Replies: 2 comments 3 replies
-
Hi @synapticlee, If you are getting a broken link image running the experiment this indicates that the path to the image file is incorrect. This would also explain why the experiment is failing to load: if there are files that cannot be found then preloading will fail. If you open the developer tools and/or console in your browser, you should see error messages for each failed image load and that will help you track down which paths are incorrect. |
Beta Was this translation helpful? Give feedback.
0 replies
-
Hi, that's why I'm confused as the stimulus path that shows up in the JSON
at the end of the experiment is correct. Is there any other reason this
could be happening?
…On Tue, 24 Jan 2023, 16:28 Josh de Leeuw, ***@***.***> wrote:
Hi @synapticlee <https://github.com/synapticlee>,
If you are getting a broken link image running the experiment this
indicates that the path to the image file is incorrect. This would also
explain why the experiment is failing to load: if there are files that
cannot be found then preloading will fail. If you open the developer tools
and/or console in your browser, you should see error messages for each
failed image load and that will help you track down which paths are
incorrect.
—
Reply to this email directly, view it on GitHub
<#2948 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/ABJA4PSRTE3YPXVIRMJWB3LWUBCP7ANCNFSM6AAAAAAUFLJKY4>
.
You are receiving this because you were mentioned.Message ID:
***@***.***>
|
Beta Was this translation helpful? Give feedback.
3 replies
Answer selected by
synapticlee
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
jspsych 6.1.0
Hi, I'm trying to preload 30 stimuli, and I'm doing this by calling a .js script called stimuli.js at the top of my HTML, which loads a var called images.
I'm then trying to preload these with,
jsPsych.init({
timeline: timeline,
preload_images: images,
on_finish: function() {
jsPsych.data.displayData(); // comment out when live
}
});
And nothing else. However when I run the experiment it says "the experiment failed to load". I only have 30 stimuli, so I'm not sure why this is a problem. Can anyone help?
I decided to preload as some of my stimuli were showing up with a broken link image when testing my experiment.
Beta Was this translation helpful? Give feedback.
All reactions