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

change number of videos in dataset class #30

Open
YoniSchirris opened this issue May 3, 2020 · 3 comments · May be fixed by #31
Open

change number of videos in dataset class #30

YoniSchirris opened this issue May 3, 2020 · 3 comments · May be fixed by #31

Comments

@YoniSchirris
Copy link
Contributor

self.number_of_videos = self.sample_data['sample_id'].max()

gives number_of_videos-1

instead, use len(sample_data.index) as given in here

@MalcolmMielle
Copy link
Contributor

Len gives the length of the column right? Since there are multiple lines (one per frame) for each sample number, what we want is the maximum number in the column 'sample_id' hence max(). Maybe add 1 since it's the index and it starts at 0 instead of one. Thus

self.number_of_videos = self.sample_data['sample_id'].max() + 1

@YoniSchirris
Copy link
Contributor Author

len(self.meta.index) works. but max+1 could also be used

@MalcolmMielle
Copy link
Contributor

Either work :)

@YoniSchirris YoniSchirris linked a pull request May 3, 2020 that will close this issue
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

Successfully merging a pull request may close this issue.

2 participants