Read the remote or local simulation output created for a project/script and
return the counts of 0 and 1 for each simulated matrix contained in the
output. The function will attempt to fetch results if the expected local
output file is missing; when necessary it will inspect the remote repository
(via SSH), possibly compress and download large logs, or attempt a remote
git refresh. If the remote results are not yet available the function may
queue or trigger a re-run via SimSlurm() and return a structured FALSE
with a reason.
Simulated01s(pID, scriptID, prefix = "stat")'Simulated01s()' returns a numeric matrix whose rows are named "0"
and "1" and whose columns correspond to each simulated matrix found
in the output log. Each column gives the total count of zeroes and ones for
that simulated matrix. If the results are not yet available the function
returns structure(FALSE, reason = <string>) describing why.
The function performs several side effects when the local output file is
missing: it calls FetchResults() to fetch output, inspects the remote
repository via SSH, and may compress large
log files, download compressed logs with scp_download() and
uncompress them locally. If the remote git repo has diverged the function
will attempt a safe pull (stash/rebase/pop) and push updates.