MolSSI / QCFractal

A distributed compute and database platform for quantum chemistry.
https://molssi.github.io/QCFractal/
BSD 3-Clause "New" or "Revised" License
143 stars 47 forks source link

Add display of number of records in a dataset #762

Closed bennybp closed 9 months ago

bennybp commented 9 months ago

Description

Adds the number of records in a dataset to the list_datasets functionality, and also the ability to request from the server the number of records in a dataset via the dataset model (ds.record_count). Requested in issue #756

The record count is computed on the fly. For now, this is fine, but we will have to keep an eye on it as the database size increases, though, as then listing dataset size could take too long. There could be more database trickery we could do.

Example output from print_dataset_list (for a small subset of the production database):

 id  type                record_count  name
----  ----------------  --------------  -----------------------------------
  48  torsiondrive                   3  SMIRNOFF Coverage Torsion Set 1
  50  optimization                   3  OpenFF Discrepancy Benchmark 1
 155  singlepoint                   24  QM9
 159  singlepoint                    3  OpenFF Discrepancy Benchmark 1
 184  manybody                       0  S22
 207  singlepoint                   24  COMP6 DrugBank
 237  gridoptimization               5  OpenFF Trivalent Nitrogen Set 2
 253  optimization                   3  OpenFF Gen 2 Opt Set 2 Coverage
 309  torsiondrive                  39  OpenFF Theory Benchmarking Set v1.0

Changelog description

Add display of number of records in a dataset, and ability to get number of records in a dataset

Status

codecov[bot] commented 9 months ago

Codecov Report

Merging #762 (7263aa7) into main (23c4103) will decrease coverage by 0.02%. The diff coverage is 61.53%.

Additional details and impacted files
j-wags commented 9 months ago

Awesome - this looks great! Sorry it took me so long, just got to this as you were merging. Thanks for putting this in!