Please use our GitHub Issues page for all new support inquiries. If you need to contact us directly, please e-mail [email protected]

I've been asked to explore the possibility of using custom scripting to add date/timestamps to our data. We have secondary data with timestamps that we would like to sync with coded behaviors. Our video will always have a date/timestamp showing.

I'm a newbie to the platform, but I see custom Ruby scripts are a possibility. In an ideal world, we'd have a way to read the date/timestamp from the first frame of the recording and calculate offsets from that date/time. Recording will be continuous, so there should be no need to recalibrate mid-playback.

Do you know if anyone has created/shared any code that can accomplish this? If not, are there pointers/tips or areas of the documentation I should focus on?

asked 13 Feb '17, 12:58

pinneycolton's gravatar image

accept rate: 0%

If I understand you correctly, you would like to read the image data and extract the time information from the image? Unfortunately, Datavyu does not support that through the Ruby API. The timestamps in the spreadsheet are linked to the timestamps reported by the media-reading libraries.

What is your end goal with this task? If you need to export the data with adjusted timestamps, you can manually input the time from the first frame of video into a separate column/cell on the spreadsheet and use that data to offset the timestamps of coded behaviors in an export script.

We can discuss this more in-depth over e-mail, if you prefer.

permanent link

answered 13 Feb '17, 14:04

Shohan%20Hasan's gravatar image

Shohan Hasan ♦♦
accept rate: 14%

Thank for your speedy reply! The forum is good for me. Ideally, I'd like to avoid the effort of the coder manually typing in timestamps when they choose to add a code for a behavior relevant to our research. This data will be blended with a secondary data source - log data collected by the devices we are observing.

I'd imagine something like this might be possible with an addition to the source code that uses a java wrapper for an OCR solution like Tesseract if it is easy to represent a point in time in the video as an image supported by Tesseract.

permanent link

answered 13 Feb '17, 14:44

pinneycolton's gravatar image

accept rate: 0%

edited 13 Feb '17, 14:46

Yes, if you want to implement this using available technologies you are of course more than welcome to do so. All of Datavyu's source code is available on GitHub. However, this is not something we can implement for you in a timely manner as all of our developers are busy with other tasks.

I don't know your data well enough, but it sounds very cumbersome to extract timing information from the image data. I would strongly suggest that you try coding the behavior using the video time if the video is a continuous recording. You can then handle synchronization outside of Datavyu.

(14 Feb '17, 12:12) Shohan Hasan ♦♦ Shohan%20Hasan's gravatar image

Thanks - I think if we decide to do this a) it wouldn't be in time for our next project, and b) I'd be able to handle it myself. It's really a question of when I have time to jump into the source code and figure things out.

...and I certainly understand the concerns about the data. For a lot of reasons, it won't align perfectly to the millisecond or even second (or minute). The OCR stuff is the least of my concerns at the moment -- I was just hoping to save the coders some time because our n size is big (500).

(14 Feb '17, 15:54) pinneycolton pinneycolton's gravatar image
Your answer
toggle preview

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here



Answers and Comments

Markdown Basics

  • *italic* or _italic_
  • **bold** or __bold__
  • link:[text]( "title")
  • image?![alt text](/path/img.jpg "title")
  • numbered list: 1. Foo 2. Bar
  • to add a line break simply add two spaces to where you would like the new line to be.
  • basic HTML tags are also supported

Question tags:


question asked: 13 Feb '17, 12:58

question was seen: 4,608 times

last updated: 14 Feb '17, 15:54

powered by OSQA