pg.ddx.io  pgsql-general@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Alban Hertroys <haramrae@gmail.com>
To: Israel Brewster <ijbrewster@alaska.edu>
Cc: PostgreSQL Mailing Lists <pgsql-general@postgresql.org>
Subject: Re: Growth planning
Date: Mon, 4 Oct 2021 22:29:05 +0200
Message-ID: <5F0C1A8D-F199-497A-B7FA-8143E48BB020@gmail.com> (raw)
In-Reply-To: <35170FC5-0A05-48F3-9ED1-F007CC1AF365@alaska.edu>
References: <35170FC5-0A05-48F3-9ED1-F007CC1AF365@alaska.edu>


> On 4 Oct 2021, at 18:22, Israel Brewster <ijbrewster@alaska.edu> wrote:

(…)

> the script owner is taking about wanting to process and pull in “all the historical data we have access to”, which would go back several years, not to mention the probable desire to keep things running into the foreseeable future.

(…)

> - The largest SELECT workflow currently is a script that pulls all available data for ONE channel of each station (currently, I suspect that will change to all channels in the near future), and runs some post-processing machine learning algorithms on it. This script (written in R, if that makes a difference) currently takes around half an hour to run, and is run once every four hours. I would estimate about 50% of the run time is data retrieval and the rest doing its own thing. I am only responsible for integrating this script with the database, what it does with the data (and therefore how long that takes, as well as what data is needed), is up to my colleague. I have this script running on the same machine as the DB to minimize data transfer times.

I suspect that a large portion of time is spent on downloading this data to the R script, would it help to rewrite it in PL/R and do (part of) the ML calculations at the DB side?

Alban Hertroys
--
If you can't see the forest for the trees,
cut the trees and you'll find there is no forest.






view thread (14+ messages)  latest in thread

Message-ID: <5F0C1A8D-F199-497A-B7FA-8143E48BB020@gmail.com>
Permalink:  ../5F0C1A8D-F199-497A-B7FA-8143E48BB020@gmail.com/
Also on:    postgresql.org/message-id/5F0C1A8D-F199-497A-B7FA-8143E48BB020@gmail.com

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients from your mail client; the link fills in
  the headers below: reply via email
  Some clients, webmail especially, drop In-Reply-To and References from
  a link, and the reply then starts a new thread: use the mbox below.

  To: pgsql-general@postgresql.org
  Cc: haramrae@gmail.com, ijbrewster@alaska.edu
  Subject: Re: Growth planning
  In-Reply-To: <5F0C1A8D-F199-497A-B7FA-8143E48BB020@gmail.com>
  References: <35170FC5-0A05-48F3-9ED1-F007CC1AF365@alaska.edu> <5F0C1A8D-F199-497A-B7FA-8143E48BB020@gmail.com>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox