ID |
Date |
Author |
Topic |
Subject |
154
|
04 Sep 2015 |
Farrukh Azfar | Forum | ARGUS display with canvas and pads ... | Dear Ryu,
we've coded up our own example menu based on what you made for us - and thank you very much for that - we notice however that the resulting menu is nowhere to be seen on the frame.
When we did buttons we had to associate them with a frame - and I note that there seems to be no association to a frame in the code you wrote for us - so we never see a menu - is
this what is to be expceted ?
thanks
Farrukh
> Hi Ryu
>
> thanks very much - I will certainly look at this example. In the meantime we are having some issues with out save buttons - I will post a thread separately
> -Farrukh
>
> > Dear Farrukh
> >
> > What you want to do is probably possible ( I will write a possible method later.).
> > However TPad has already several mouse operations (zoom, right-click menu, select active pad and so on); so I am not sure it is the best idea to add own mouse operation (which
> > could override other pre-implemented operations.)
> > I will write three solutions below.
> > I wrote an example of the first method.
> >
> > == Method 1 : Menu ==
> > For this solutions, I modified an example in the ROME package.
> > The update is done only in the 'develop' branch.
> > You can read the example by 'git checkout develop' command after you clone the ROME package.
> > The example is in $ROMESYS/examples/argus/menu and the third tab (T3) is one for that.
> > In ROME, you can easily add menu items in the menu bar. In the example, menu items to open and save a specific tab are prepared.
> >
> > == Method 2 : dedicated buttons ==
> > If you prefer buttons instead of menu, you can put dedicated buttons to trigger "OpenPad" function in the example instead of adding menus. The buttons can be implemented
> > either of the following two methods,
> > 1) TButton, which can work as the same way as your Save button
> > 2) Writing own class derived from TBox or TMarker. A box or maker can be put on each canvas.
> >
> > I hope the first method is obvious for you. You can make another button similar to your Save button and call "OpenPad" function.
> >
> > The second method is a little more complicated; you make your own class and override "ExecuteEvent" method.
> > In the overriding function, you can call any functions when the box or marker is single-clicked, double-clicked, mouse-over and so on.
> > A disadvantage is that the box or marker is always visible, and will be drawn in the output PDF files too.
> >
> > == Method 3: click on Pad ==
> > You can probably do what you write with making own class derived from TPad; then you override "ExecuteEvent" function for calling a function to make a separated canvas and
> > draw a clone of itself.
> > You may also need own TCanvas and TRootEmbeddedCanvas for using the customized classes instead of regular TPad and TCanvas.
> >
> > If you are satisfied with the first method, please try the example.
> > The second method with TButton must not be very difficult.
> >
> > If you prefer the second (using TBox or TMarker) and third method, I will investigate if it is actually possible.
> > For the two methods, I think you need to write your own classes.
> >
> > Best regards,
> >
> > Ryu
> >
> > > Dear Colleagues,
> > >
> > > We are succesfully running a ROME executable both online and offline with an
> > > ARGUS display with a canvas that has multiple pads on it. We have also
> > > implemented a "Save" button which one can click on and save the _entire_ canvas
> > > (containing all the pads) and saves it to pdf.
> > >
> > > I was wondering how one would go about making the following modification :
> > >
> > > When a user moves a mouse over to a particular pad and clicks on it - then only
> > > the histogram on that pad is displayed on a separate canvas (so the user can
> > > examine it closely) and also save just this one histogram - with a save button
> > > similar to the one we've already written.
> > >
> > > many thanks for any insight
> > >
> > > Farrukh |
155
|
04 Sep 2015 |
Ryu Sawada | Forum | ARGUS display with canvas and pads ... | Dear Farrukh
The menu items are defined in,
examples/argus/menu/menu.xml, in the part for 'T3' tab.
Did you modify the definition XML for your program ?
Ryu
> Dear Ryu,
>
> we've coded up our own example menu based on what you made for us - and thank you very much
for that - we notice however that the resulting menu is nowhere to be seen on the frame.
>
> When we did buttons we had to associate them with a frame - and I note that there seems to be no
association to a frame in the code you wrote for us - so we never see a menu - is
> this what is to be expceted ?
>
> thanks
> Farrukh
>
> > Hi Ryu
> >
> > thanks very much - I will certainly look at this example. In the meantime we are having some
issues with out save buttons - I will post a thread separately
> > -Farrukh
> >
> > > Dear Farrukh
> > >
> > > What you want to do is probably possible ( I will write a possible method later.).
> > > However TPad has already several mouse operations (zoom, right-click menu, select active pad
and so on); so I am not sure it is the best idea to add own mouse operation (which
> > > could override other pre-implemented operations.)
> > > I will write three solutions below.
> > > I wrote an example of the first method.
> > >
> > > == Method 1 : Menu ==
> > > For this solutions, I modified an example in the ROME package.
> > > The update is done only in the 'develop' branch.
> > > You can read the example by 'git checkout develop' command after you clone the ROME
package.
> > > The example is in $ROMESYS/examples/argus/menu and the third tab (T3) is one for that.
> > > In ROME, you can easily add menu items in the menu bar. In the example, menu items to open
and save a specific tab are prepared.
> > >
> > > == Method 2 : dedicated buttons ==
> > > If you prefer buttons instead of menu, you can put dedicated buttons to trigger "OpenPad"
function in the example instead of adding menus. The buttons can be implemented
> > > either of the following two methods,
> > > 1) TButton, which can work as the same way as your Save button
> > > 2) Writing own class derived from TBox or TMarker. A box or maker can be put on each
canvas.
> > >
> > > I hope the first method is obvious for you. You can make another button similar to your Save
button and call "OpenPad" function.
> > >
> > > The second method is a little more complicated; you make your own class and override
"ExecuteEvent" method.
> > > In the overriding function, you can call any functions when the box or marker is single-clicked,
double-clicked, mouse-over and so on.
> > > A disadvantage is that the box or marker is always visible, and will be drawn in the output PDF
files too.
> > >
> > > == Method 3: click on Pad ==
> > > You can probably do what you write with making own class derived from TPad; then you
override "ExecuteEvent" function for calling a function to make a separated canvas and
> > > draw a clone of itself.
> > > You may also need own TCanvas and TRootEmbeddedCanvas for using the customized classes
instead of regular TPad and TCanvas.
> > >
> > > If you are satisfied with the first method, please try the example.
> > > The second method with TButton must not be very difficult.
> > >
> > > If you prefer the second (using TBox or TMarker) and third method, I will investigate if it is
actually possible.
> > > For the two methods, I think you need to write your own classes.
> > >
> > > Best regards,
> > >
> > > Ryu
> > >
> > > > Dear Colleagues,
> > > >
> > > > We are succesfully running a ROME executable both online and offline with an
> > > > ARGUS display with a canvas that has multiple pads on it. We have also
> > > > implemented a "Save" button which one can click on and save the _entire_ canvas
> > > > (containing all the pads) and saves it to pdf.
> > > >
> > > > I was wondering how one would go about making the following modification :
> > > >
> > > > When a user moves a mouse over to a particular pad and clicks on it - then only
> > > > the histogram on that pad is displayed on a separate canvas (so the user can
> > > > examine it closely) and also save just this one histogram - with a save button
> > > > similar to the one we've already written.
> > > >
> > > > many thanks for any insight
> > > >
> > > > Farrukh |
159
|
07 Sep 2015 |
Ryu Sawada | Forum | ARGUS display with canvas and pads ... | I found rather easy way for the Method 3 (click on pad).
I implemented in the same example,
namely, the third tab in $ROMESYS/examples/argus/menu.
You can add a macro which is executed when an event occurs on each pad with,
fCanvas->GetCanvas()->GetPad(1)->AddExec("ex1", ".x OpenCanvas.C");
Then you can write any function in the macro.
In this example, it opens a copy of canvas and save the clicked pad into a PDF file.
Ryu
> Dear Farrukh
>
> What you want to do is probably possible ( I will write a possible method later.).
> However TPad has already several mouse operations (zoom, right-click menu, select active pad
and so on); so I am not sure it is the best idea to add own mouse operation (which
> could override other pre-implemented operations.)
> I will write three solutions below.
> I wrote an example of the first method.
>
> == Method 1 : Menu ==
> For this solutions, I modified an example in the ROME package.
> The update is done only in the 'develop' branch.
> You can read the example by 'git checkout develop' command after you clone the ROME package.
> The example is in $ROMESYS/examples/argus/menu and the third tab (T3) is one for that.
> In ROME, you can easily add menu items in the menu bar. In the example, menu items to open and
save a specific tab are prepared.
>
> == Method 2 : dedicated buttons ==
> If you prefer buttons instead of menu, you can put dedicated buttons to trigger "OpenPad" function
in the example instead of adding menus. The buttons can be implemented
> either of the following two methods,
> 1) TGTextButton, which can work as the same way as your Save button
> 2) Writing own class derived from TBox or TMarker. A box or maker can be put on each canvas.
>
> I hope the first method is obvious for you. You can make another button similar to your Save button
and call "OpenPad" function.
>
> The second method is a little more complicated; you make your own class and override
"ExecuteEvent" method.
> In the overriding function, you can call any functions when the box or marker is single-clicked,
double-clicked, mouse-over and so on.
> A disadvantage is that the box or marker is always visible, and will be drawn in the output PDF files
too.
>
> == Method 3: click on Pad ==
> You can probably do what you write with making own class derived from TPad; then you override
"ExecuteEvent" function for calling a function to make a separated canvas and
> draw a clone of itself.
> You may also need own TCanvas and TRootEmbeddedCanvas for using the customized classes
instead of regular TPad and TCanvas.
>
> If you are satisfied with the first method, please try the example.
> The second method with TGTextButton must not be very difficult.
>
> If you prefer the second (using TBox or TMarker) and third method, I will investigate if it is actually
possible.
> For the two methods, I think you need to write your own classes.
>
> Best regards,
>
> Ryu
>
> > Dear Colleagues,
> >
> > We are succesfully running a ROME executable both online and offline with an
> > ARGUS display with a canvas that has multiple pads on it. We have also
> > implemented a "Save" button which one can click on and save the _entire_ canvas
> > (containing all the pads) and saves it to pdf.
> >
> > I was wondering how one would go about making the following modification :
> >
> > When a user moves a mouse over to a particular pad and clicks on it - then only
> > the histogram on that pad is displayed on a separate canvas (so the user can
> > examine it closely) and also save just this one histogram - with a save button
> > similar to the one we've already written.
> >
> > many thanks for any insight
> >
> > Farrukh |
164
|
23 Oct 2015 |
Wes Gohn | Forum | TGraph objects | Does anyone have an example of how to add TGraph objects in ROME? We often use these in our MIDAS analyzers to create plots of quantities vs. event number (i.e. bank size, number of triggers, etc). Thanks! |
165
|
23 Oct 2015 |
Joe Grange | Forum | Running ROME in online mode | Hi folks,
I've been a happy and successful user of rome in the offline mode for some time,
and now when I try and connect it to a current run the analyzer does not find
the current file. I attach a screenshot - you can see when I run the analyzer
instead of reporting a successful connection to a midas file it says it starts Run
#-1. I use a file path specified in romeConfig.xml which is successful when I run
in offline mode but not in online mode, even when I specify the file path with the
run-time argument -pi. Any ideas what may be the trouble?
I did verify that my romeConfig.xml file specifies the online mode run configuration.
Thanks very much,
Joe |
Attachment 1: Screen_Shot_2015-10-23_at_11.56.12_AM.png
|
|
166
|
24 Oct 2015 |
Robert Pattie | Forum | ROME / Argus crashing between runs with MIDAS | I'm running ROME+Argus as an online analyzer and display for a MIDAS DAQ system.
In our set up there is generally a few seconds between MIDAS runs. ROME
handles the first run just fine, but always crashes when runs are taken in quick
succession like this. When running in a slower mode, letting ROME finish
whatever run of end task exist, the online analyzer does not have this problem.
I've suppressed writing all output files while in the online mode and I don't
have any end of run operations in any of the tasks. What is happening at the
end of running that is causing ROME to crash?
Thanks for any help. |
167
|
26 Oct 2015 |
Konstantin Olchanski | Forum | ROME / Argus crashing between runs with MIDAS | > I'm running ROME+Argus as an online analyzer and display for a MIDAS DAQ system.
> In our set up there is generally a few seconds between MIDAS runs. ROME
> handles the first run just fine, but always crashes when runs are taken in quick
> succession like this. When running in a slower mode, letting ROME finish
> whatever run of end task exist, the online analyzer does not have this problem.
> I've suppressed writing all output files while in the online mode and I don't
> have any end of run operations in any of the tasks. What is happening at the
> end of running that is causing ROME to crash?
>
> Thanks for any help.
You have to provide a stack trace from your crash. RTFM the gdb command "where".
K.O. |
168
|
29 Oct 2015 |
Ryu Sawada | Forum | TGraph objects | Hello,
You can find an example in $ROMESYS/examples/histoGUI
Graphs are defined in histoGUI.xml and the data points are set in src/tasks/HGUITFillHisto.cpp
Best regards,
Ryu
> Does anyone have an example of how to add TGraph objects in ROME? We often use these in our MIDAS analyzers to create plots of quantities vs. event number (i.e. bank size, number of triggers, etc). Thanks! |
169
|
29 Oct 2015 |
Ryu Sawada | Forum | Running ROME in online mode | Dear Joe
In the online mode, the analyzer does not read midas files.
Instead, it connects to a midas experiment over the network or to the local shared memory.
Same as other midas online applications, you may need to specify the hostname of the midas system and the
experiment name.
You can set the parameters in the <Online> section of your configuration XML file.
Of course, the midas system has to be ready to accept the connection.
You can check it, for example, using 'odbedit' command.
Best regards,
Ryu
> Hi folks,
>
> I've been a happy and successful user of rome in the offline mode for some time,
> and now when I try and connect it to a current run the analyzer does not find
> the current file. I attach a screenshot - you can see when I run the analyzer
> instead of reporting a successful connection to a midas file it says it starts Run
> #-1. I use a file path specified in romeConfig.xml which is successful when I run
> in offline mode but not in online mode, even when I specify the file path with the
> run-time argument -pi. Any ideas what may be the trouble?
>
> I did verify that my romeConfig.xml file specifies the online mode run configuration.
>
> Thanks very much,
> Joe |
170
|
29 Oct 2015 |
Ryu Sawada | Forum | ROME / Argus crashing between runs with MIDAS | Hello,
You can try to set <MidasOnlineCommunicationThread>to be true in your config XML file.
By doing it, the communication with the midas system will be done in a dedicated thread so it runs independently
of analysis tasks.
Ryu
> I'm running ROME+Argus as an online analyzer and display for a MIDAS DAQ system.
> In our set up there is generally a few seconds between MIDAS runs. ROME
> handles the first run just fine, but always crashes when runs are taken in quick
> succession like this. When running in a slower mode, letting ROME finish
> whatever run of end task exist, the online analyzer does not have this problem.
> I've suppressed writing all output files while in the online mode and I don't
> have any end of run operations in any of the tasks. What is happening at the
> end of running that is causing ROME to crash?
>
> Thanks for any help. |
171
|
05 Nov 2015 |
Joe Grange | Forum | Running ROME in online mode | Dear Ryu,
Thanks for your response. Unfortunately setting these parameters in the XML file does not change the apparent
behavior and I still cannot connect to the experiment in online mode. I also notice that other colleagues
working with independent experiments successfully run ROME in the online mode without setting the parameters
in the <online> section of the XML file.
Can you tell me how I can verify the system is ready to accept the connection with the odbedit command? I can
verify all basic information such as experiment name, run number, are as expected but I wonder if you mean
something more specific.
Thank you,
Joe |
172
|
08 Nov 2015 |
Ryu Sawada | Forum | Running ROME in online mode | Dear Joe,
Did you run ROMEBuilder for your application with -midas option ?
With this option, MIDAS library is linked to the application for communicating with MIDAS experiments.
Actual connection is done with using a function implemented in the MIDAS library.
This is the code where a ROME application connects to MIDAS.
(You can see this in $ROMESYS/src/ROMEMidasDAQ.cpp)
cm_connect_experiment is implemented in $MIDASSYS/src/midas.c
//______________________________________________________________________________
Bool_t ROMEMidasDAQ::ConnectExperiment(ROMEMidasDAQ *localThis)
{
// Connect to the experiment
#if defined( HAVE_MIDAS )
if (cm_connect_experiment(const_cast<char*>(gROME->GetOnlineHost()),
const_cast<char*>(gROME->GetOnlineExperiment()),
const_cast<char*>(gROME->GetOnlineAnalyzerName()), 0) != SUCCESS) {
ROMEPrint::Error("\nCan not connect to experiment\n");
return kFALSE;
}
Can you check if this function is called by adding
cout<<"HERE"<<endl;
before the 'if' line and compile your application ?
If you didn't use -midas option when you run ROMEBuilder, HAVE_MIDAS will not be defined and cm_connect_experiment will not be called.
When nothing is written in <online> section of XML, I think the application tries to connect to the localhost with the experiment name defined in /etc/exptab.
I didn't mean anything specific about odbedit.
I guess if you can connect the MIDAS system with odbedit, then the system is ready to accept analyzer too.
But you could ask also MIDAS experts about this issue.
Ryu
> Dear Ryu,
>
> Thanks for your response. Unfortunately setting these parameters in the XML file does not change the apparent
> behavior and I still cannot connect to the experiment in online mode. I also notice that other colleagues
> working with independent experiments successfully run ROME in the online mode without setting the parameters
> in the <online> section of the XML file.
>
> Can you tell me how I can verify the system is ready to accept the connection with the odbedit command? I can
> verify all basic information such as experiment name, run number, are as expected but I wonder if you mean
> something more specific.
>
> Thank you,
> Joe |
173
|
16 Nov 2015 |
Joe Grange | Forum | Running ROME in online mode | Dear Ryu,
Thanks very much, indeed it was user error and I did not set -midas option at the compilation stage.
Joe
Ryu Sawada wrote: | Dear Joe,
Did you run ROMEBuilder for your application with -midas option ?
With this option, MIDAS library is linked to the application for communicating with MIDAS experiments.
Actual connection is done with using a function implemented in the MIDAS library.
This is the code where a ROME application connects to MIDAS.
(You can see this in $ROMESYS/src/ROMEMidasDAQ.cpp)
cm_connect_experiment is implemented in $MIDASSYS/src/midas.c
//______________________________________________________________________________
Bool_t ROMEMidasDAQ::ConnectExperiment(ROMEMidasDAQ *localThis)
{
// Connect to the experiment
#if defined( HAVE_MIDAS )
if (cm_connect_experiment(const_cast<char*>(gROME->GetOnlineHost()),
const_cast<char*>(gROME->GetOnlineExperiment()),
const_cast<char*>(gROME->GetOnlineAnalyzerName()), 0) != SUCCESS) {
ROMEPrint::Error("\nCan not connect to experiment\n");
return kFALSE;
}
Can you check if this function is called by adding
cout<<"HERE"<<endl;
before the 'if' line and compile your application ?
If you didn't use -midas option when you run ROMEBuilder, HAVE_MIDAS will not be defined and cm_connect_experiment will not be called.
When nothing is written in <online> section of XML, I think the application tries to connect to the localhost with the experiment name defined in /etc/exptab.
I didn't mean anything specific about odbedit.
I guess if you can connect the MIDAS system with odbedit, then the system is ready to accept analyzer too.
But you could ask also MIDAS experts about this issue.
Ryu
> Dear Ryu,
>
> Thanks for your response. Unfortunately setting these parameters in the XML file does not change the apparent
> behavior and I still cannot connect to the experiment in online mode. I also notice that other colleagues
> working with independent experiments successfully run ROME in the online mode without setting the parameters
> in the <online> section of the XML file.
>
> Can you tell me how I can verify the system is ready to accept the connection with the odbedit command? I can
> verify all basic information such as experiment name, run number, are as expected but I wonder if you mean
> something more specific.
>
> Thank you,
> Joe |
|
180
|
18 Feb 2016 |
Joe Grange | Forum | Online mode issue | Hello all,
I'm having an issue with getting rome to run in online mode in some cases only.
That is, when I run the analyzer that accesses the INPT bank (standard for PSI
slow control buses) the online mode works just fine. But when I access other
banks, when I run in online mode only blank canvases are updated and no data
appears.
I can run all of these analyzers in offline mode and they all work as expected
so this eliminates many common user bugs. Any ideas how I might debug further?
I also tried printing the data in the various tasks and indeed in online mode
no data is being accessed.
Thanks,
Joe |
183
|
02 Mar 2016 |
Ryu Sawada | Forum | Online mode issue | Dear Joe
There is a working example for the online access to midas.
Please see,
https://bitbucket.org/muegamma/rome3/wiki/Midas
The example is $ROMESYS/examples/midas.
There is a README file in the directory.
The example works with an example experiment in MIDAS package so you can try.
If you look at ADC2 tab, the histograms should be updated when DAQ is running.
The "Trigger" events are polled in the MIDAS frontend, and "Scaler" data are taken periodically.
So I guess the "Scaler" corresponds to your INPT and "Trigger" corresponds to your other event types.
You may compare the examples and your analyzer/frontend for finding the cause of your problem.
Ryu
> Hello all,
>
> I'm having an issue with getting rome to run in online mode in some cases only.
> That is, when I run the analyzer that accesses the INPT bank (standard for PSI
> slow control buses) the online mode works just fine. But when I access other
> banks, when I run in online mode only blank canvases are updated and no data
> appears.
>
> I can run all of these analyzers in offline mode and they all work as expected
> so this eliminates many common user bugs. Any ideas how I might debug further?
> I also tried printing the data in the various tasks and indeed in online mode
> no data is being accessed.
>
> Thanks,
> Joe |
185
|
10 Mar 2016 |
Farrukh Azfar | Forum | Option to analyse every Nth event | Dear Colleagues
I was wondering if there was an option to analyse only ever N events in ROME. If
this is doable via an xml switch I am guessing this would be the best and most
convenient solution.
Else any advice on how to do this in code would be great as well -
many thanks
Farrukh |
187
|
13 Mar 2016 |
Ryu Sawada | Forum | Option to analyse every Nth event | I added a new parameter <EventStep> to configuration XML file.
The default is 1.
If you change it to, for example 2, every second events are analyzed.
For using it, you need to
- update ROME
- compile ROME
- re-build and make your project
Once you use an existing config XML file, a new parameter will be automatically added to it.
Ryu
> Dear Colleagues
>
> I was wondering if there was an option to analyse only ever N events in ROME. If
> this is doable via an xml switch I am guessing this would be the best and most
> convenient solution.
>
> Else any advice on how to do this in code would be great as well -
>
> many thanks
> Farrukh |
Draft
|
28 Feb 2018 |
Francesco Renga | Forum | DB path | Dear all,
I need to perform a DB query in ROME, where I have to select an array of |
213
|
23 Jul 2019 |
Yusuke Uchiyama | Forum | Change of MIDAS library path | Dear all,
From the recent release of MIDAS, "midas-2019-06", the MIDAS library path is changed:
it was $MIDASSYS/linux/lib, but now $MIDASSYS/lib.
See https://midas.triumf.ca/elog/Midas/1564 for the detail.
Due to this change, ROME analyzers cannot be built with -midas option.
The solution seems easy: change the path in
$ROMESYS/buildersrc/ROMEBuilderMakeFile.cpp AddDAQLibraries().
However, directly changing the code will loose backward compatibility.
Do you have any suggestions?
Regards,
Yusuke |
4
|
11 Oct 2004 |
Matthias Schneebeli | Info | Schema evolution in root and rome | For your information:
ROOT has an automatic schema evolution implemented. That means, that all trees
can be filled into a class from a file, even if the class definition has
changed (take a look at the input/output section in the root manual).
This works also in the rome environment. All you have to do is to increment the
version number of a folder, every time you change the folder.
This works for adding, removeing or changing fields. However, if you remove or
change a field you will have to change your user code, because the Get and Set
methods will be changed or removed too. So you better think twice about the
contents of a folder.
Matthias |
|