def METHOD_NAME(self, rowids):
    sql = "select rowid, blocks from pictures where rowid in (%s)" % ",".join(map(str, rowids))
    cur = self.con.execute(sql)
    return ((rowid, bytes_to_colors(blocks)) for rowid, blocks in cur)