Get gpu/cpu utilization time series

Hi, just for the time series displayed in timeline view (cpu utilization and cpu utilization), is there any chance we can calculate from the data in sqlite database? Thanks.