Skip to content
This repository has been archived by the owner on Jul 15, 2021. It is now read-only.

dicarlo.Seibert2019 #48

Merged
merged 5 commits into from
Dec 3, 2020
Merged

dicarlo.Seibert2019 #48

merged 5 commits into from
Dec 3, 2020

Conversation

jjpr-mit
Copy link
Contributor

No description provided.

@mschrimpf
Copy link
Member

please add unit tests -- see e.g. https://github.com/brain-score/brainio_collection/pull/37/files,

def test_klab_Zhang2018search():
assembly = brainio_collection.get_assembly('klab.Zhang2018search_obj_array')
assert set(assembly.dims) == {'presentation', 'fixation', 'position'}
assert len(assembly['presentation']) == 4500
assert len(set(assembly['image_id'].values)) == 300
assert len(set(assembly['subjects'].values)) == 15
assert len(assembly['fixation']) == 8
assert len(assembly['position']) == 2
assert assembly.stimulus_set is not None
, and
def test_klab_Zhang2018search():
stimulus_set = brainio_collection.get_stimulus_set('klab.Zhang2018.search_obj_array')
# There are 300 presentation images in the assembly but 606 in the StimulusSet (explanation from @shashikg follows).
# For each of the visual search task out of total 300, you need two images (one - the target image,
# second - the search space image) plus there are 6 different mask images to mask objects
# present at 6 different locations in a specified search image.
# Therefore, a total of 300 * 2 + 6 images are there in the stimulus set.
assert len(stimulus_set) == 606
assert len(set(stimulus_set['image_id'])) == 606
@pytest.mark.private_access
def test_feifei_Deng2009():
stimulus_set = brainio_collection.get_stimulus_set('fei-fei.Deng2009')
assert len(stimulus_set) == 50_000
assert len(set(stimulus_set['label'])) == 1_000

@mschrimpf
Copy link
Member

mschrimpf commented Dec 1, 2020

@jjpr-mit if you also add the stimulus_set test(s) and make sure they pass, I think we're good!

@jjpr-mit
Copy link
Contributor Author

jjpr-mit commented Dec 1, 2020

@jjpr-mit if you also add the stimulus_set test(s) and make sure they pass, I think we're good!

There's no new StimulusSet. It's HvM.

@mschrimpf mschrimpf merged commit cdccab2 into master Dec 3, 2020
jjpr-mit added a commit that referenced this pull request Dec 4, 2020
* master:
  dicarlo.Seibert2019 (#48)

# Conflicts:
#	tests/test_assemblies.py
jjpr-mit added a commit that referenced this pull request Jan 20, 2021
Also fix tests for dicarlo.BashivanKar2019 as only two assemblies

* master:
  Rust305 (#51)
  Fix Kuzovkin 2018 (#50)
  Inplace (#47)
  dicarlo.Seibert2019 (#48)
  add ImageNet stimulus set (#45)
  Created exceptions in fetch and packaging for PropertyAssembly class that do not merge responses with stimulus_set (#42)
  Update lookup.csv (#44)
  Update Rajalingham2020 lookup (#43)
  Update lookup.csv (#41)
  use image_file_name without .png if present (#40)

# Conflicts:
#	tests/test_assemblies.py
#	tests/test_stimuli.py
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants