Hi Scott,
We use the IconNMR accounting file to produce the billing output that we need,
either from a perl script or a similar-minded gawk script; the perl script has
a minimum of overhead and can be used at any interval that is necessary. We
execute the script on a terminal, and capture the output in a text file, which
can be dumped into Excel -
GDbtra GD 07/02/2023 23:53:08 07/03/2023 00:01:19 0.1364 QuickBoron
ARrher AR 07/03/2023 00:01:19 07/03/2023 00:04:41 0.0561 PROTON
GAfkuo GA 07/03/2023 00:04:41 07/03/2023 00:08:24 0.0619 PROTON
GAfkuo GA 07/03/2023 00:08:25 07/03/2023 00:21:49 0.2233 C13CPD
CMczha CM 07/03/2023 00:21:49 07/03/2023 01:38:03 1.2706 C13CPD
CMczha CM 07/03/2023 01:38:03 07/03/2023 02:10:54 0.5475 C13DEPT135
The username and user group are the first two fields, followed by the start
and stop time of the run and the total time for the sample (from the time
the sample changer picks up the sample to the time it is returned to the
carousel). Samples that fail are skipped, as are experiments done by "nmrsu"
or a similar administrator account.
I developed the script when I was at Dana-Farber and ported it over to MIT
without much trouble; let me know if it would be useful to you and I will
happily send it over!
Best,
Walt
-------------------------------
Walter Massefski, Ph.D.
Director
Department of Chemistry Instrumentation Facility
Massachusetts Institute of Technology
77 Mass. Ave. Rm: 18-0090
Cambridge, MA 02139
T: (617) 253-2016
wwm_at_mit.edu<mailto:wwm_at_mit.edu>
On Jul 28, 2023, at 5:41 PM, Scott Burt via groups.io wrote:
After 15 years of relative bliss (at least in this specific area), I will
soon be required to charge user fees to recover the operating costs for our
NMR facility. I've spent some time playing around with the built in accounting
options in OpenVnmrJ 3.1 and TopSpin 4.1.4 and I must say that I'm deeply
underwhelmed. That means I need to process the log files directly to get
the data that I'm interested in.
I have successfully done some quick and dirty processing of the log files to
at least get some rough statistics on how sample times per user, start/stop
time distributions, etc. (vnmrsys/Automation/auto*/logfile for OVJ and
/opt/topspin4.1.4/prog/curdir/changer/inmrchanger/*hist for TS) However,
my current approach is messy and too much of a hack for real accounting.
Before embarking on a writing myself a better processing script, I figured
I should check here to see what kind of scripts people have already created
for extracting information from OVJ and TS.
(Details for those interested)
My goal is to generate a CSV file that gives me a list of each sample submitted,
the operator username who submitted the sample, the date and time that the sample
was started, and the total instrument time that the sample took. My goal is to
have a per sample charge and then a flat rate per minute on top of that (with
the typical "off hours" being cheaper than "busy hours"). The primary problems
with the built in software are
1) OVJ per sample charge isn't actually a per sample charge. For example,
a sample submitted with a proton, carbon, and COSY will trigger several "go"
charges during the lock and shim stage (it appears to apply a "go" charge
for every iteration of the automated shimming!) and then several go charges
for each of the protocols (i.e., it appears to charge a "go" for the automated
gain setting and then one for the actual acquisition).
2) The TopSpin .csv generation appears to be useless - most of the fields are
blank (no info about individual operators within a group, etc.) The summary
file provides a lot of useful data, but then I would have to convert that .tmp
file into a CSV format. Even then, there doesn't appear to be a way to have a
per sample charge, just a flat rate per time. It also appears that there is
no account taken for the time to lock, tune, shim, etc. (that's where having
a fixed per sample charge would be helpful).
I can't use anything that's tied to a scheduling page or a resource request
page because we don't schedule the instruments (they have auto-samplers).
I want the charges to reflect actual usage vs. incomplete/inaccurate user-provided
data. I guess I should note that all my systems run on RedHat, so Windows-based
scripts aren't directly helpful (although the logic/approach might be useful).
I'm interested to see what tools people have already come up with.
-Scott
-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.
View/Reply Online (#387): https://urldefense.com/v3/__https://ammrl.groups.=
io/g/main/message/387__;!!PvDODwlR4mBZyAb0!TNGwOg9VLDH-ywf2CiUrKUvalTMzmtns=
YuG2TVRSRPfvRsF73O1lutMaPzlbmpa2nbJs6a18kQ$
Mute This Topic: https://urldefense.com/v3/__https://groups.io/mt/100419616=
/7559972__;!!PvDODwlR4mBZyAb0!TNGwOg9VLDH-ywf2CiUrKUvalTMzmtnsYuG2TVRSRPfvR=
sF73O1lutMaPzlbmpa2nbKehPXaOw$
Mute #question:
https://urldefense.com/v3/__https://ammrl.groups.io/g/main/m=
utehashtag/question__;!!PvDODwlR4mBZyAb0!TNGwOg9VLDH-ywf2CiUrKUvalTMzmtnsYu=
G2TVRSRPfvRsF73O1lutMaPzlbmpa2nbLs0sv5yw$
Mute #varian:
https://urldefense.com/v3/__https://ammrl.groups.io/g/main/mut=
ehashtag/varian__;!!PvDODwlR4mBZyAb0!TNGwOg9VLDH-ywf2CiUrKUvalTMzmtnsYuG2TV=
RSRPfvRsF73O1lutMaPzlbmpa2nbJy-M9PkA$
Mute #varianagilent:
https://urldefense.com/v3/__https://ammrl.groups.io/g/m=
ain/mutehashtag/varianagilent__;!!PvDODwlR4mBZyAb0!TNGwOg9VLDH-ywf2CiUrKUva=
lTMzmtnsYuG2TVRSRPfvRsF73O1lutMaPzlbmpa2nbJ1pUlwVA$
Mute #bruker:
https://urldefense.com/v3/__https://ammrl.groups.io/g/main/mut=
ehashtag/bruker__;!!PvDODwlR4mBZyAb0!TNGwOg9VLDH-ywf2CiUrKUvalTMzmtnsYuG2TV=
RSRPfvRsF73O1lutMaPzlbmpa2nbJL-CDj5Q$
Group Owner: main+owner_at_ammrl.groups.io
-=-=-=-=-=-=-=-=-=-=-=-
Received on Fri Jul 28 2023 - 16:01:54 MST