Slow down of

classic Classic list List threaded Threaded
3 messages Options
Reply | Threaded
Open this post in threaded view
|

Slow down of

C.N.McMurray

Hi Micromanager Community,


I have been experiencing significant delays in the interaction with the micromanager GUI. The delays seem to be exacerbated when more devices are installed in a given configuration and reduced if devices are removed form the configuration.


in the following email I reference full configuration and a basic/reduced configuration the following configurations are outlined below


basic/reduced configuration


# Generated by Configurator on Thu Nov 29 10:35:51 GMT 2018

# Reset
Property,Core,Initialize,0

# Devices
Device,COM9,SerialManager,COM9
Device,OlympusHub,Olympus,OlympusHub
Device,Objective,Olympus,Objective
Device,ReflectedLamp,Olympus,FluorescenceLamp
Device,OlympusZStage,Olympus,ManualFocus

# Pre-init settings for devices
Property,OlympusHub,Port,COM9

# Pre-init settings for COM ports
Property,COM9,AnswerTimeout,500.0000
Property,COM9,BaudRate,19200
Property,COM9,DelayBetweenCharsMs,0.0000
Property,COM9,Handshaking,Off
Property,COM9,Parity,Even
Property,COM9,StopBits,2
Property,COM9,Verbose,1

# Hub (parent) references

# Initialize
Property,Core,Initialize,1

# Delays

# Focus directions
FocusDirection,OlympusZStage,0

# Roles
Property,Core,Focus,OlympusZStage
Property,Core,AutoShutter,1

# Camera-synchronized devices

# Labels
# Objective
Label,Objective,4,x 100
Label,Objective,3,x 50
Label,Objective,2,x 20
Label,Objective,1,x 10
Label,Objective,0,x 5
# ReflectedLamp
Label,ReflectedLamp,1,On
Label,ReflectedLamp,0,Off

# Configuration presets
# Group: Objective
# Preset: x 10
ConfigGroup,Objective,x 10,Objective,Label,x 10

# Preset: x 100
ConfigGroup,Objective,x 100,Objective,Label,x 100

# Preset: x 20
ConfigGroup,Objective,x 20,Objective,Label,x 20

# Preset: x 5
ConfigGroup,Objective,x 5,Objective,Label,x 5

# Preset: x 50
ConfigGroup,Objective,x 50,Objective,Label,x 50


# Group: Channel

# Group: Control
# Preset: Computer
ConfigGroup,Control,Computer,OlympusHub,Control,Computer

# Preset: Manual + Computer
ConfigGroup,Control,Manual + Computer,OlympusHub,Control,Manual + Computer


# Group: Light
# Preset: On
ConfigGroup,Light,On,ReflectedLamp,Label,On

# Preset: Off
ConfigGroup,Light,Off,ReflectedLamp,Label,Off


# Group: Light-voltage
# Preset: NewPreset
ConfigGroup,Light-voltage,NewPreset,ReflectedLamp,Voltage,12.0000



# PixelSize settings
# Resolution preset: x 10
ConfigPixelSize,x 10,Objective,Label,x 10
PixelSize_um,x 10,0.4538

# Resolution preset: x 100
ConfigPixelSize,x 100,Objective,Label,x 100
PixelSize_um,x 100,0.0448

# Resolution preset: x 20
ConfigPixelSize,x 20,Objective,Label,x 20
PixelSize_um,x 20,0.2283

# Resolution preset: x 5
ConfigPixelSize,x 5,Objective,Label,x 5
PixelSize_um,x 5,0.9097

# Resolution preset: x 50
ConfigPixelSize,x 50,Objective,Label,x 50
PixelSize_um,x 50,0.0906


full configuration

# Generated by Configurator on Tue Jul 17 09:58:52 BST 2018

# Reset
Property,Core,Initialize,0

# Devices
Device,COM9,SerialManager,COM9
Device,COM5,SerialManager,COM5
Device,COM7,SerialManager,COM7
Device,COM4,SerialManager,COM4
Device,PI_GCSController_Y,PI_GCS_2,PI_GCSController
Device,PI_GCSController_X,PI_GCS_2,PI_GCSController
Device,PIXYStage,PI_GCS_2,PIXYStage
Device,OlympusHub,Olympus,OlympusHub
Device,Objective,Olympus,Objective
Device,ReflectedLamp,Olympus,FluorescenceLamp
Device,OlympusZStage,Olympus,ManualFocus
Device,RetigaR3,PVCAM,Camera-1
Device,PIZStage,PI_GCS,PIZStage

# Pre-init settings for devices
Property,COM9,AnswerTimeout,500.0000
Property,COM9,BaudRate,19200
Property,COM9,DelayBetweenCharsMs,0.0000
Property,COM9,Handshaking,Off
Property,COM9,Parity,Even
Property,COM9,StopBits,2
Property,COM9,Verbose,1
Property,COM5,AnswerTimeout,500.0000
Property,COM5,BaudRate,115200
Property,COM5,DelayBetweenCharsMs,0.0000
Property,COM5,Handshaking,Off
Property,COM5,Parity,None
Property,COM5,StopBits,1
Property,COM5,Verbose,1
Property,COM7,AnswerTimeout,500.0000
Property,COM7,BaudRate,115200
Property,COM7,DelayBetweenCharsMs,0.0000
Property,COM7,Handshaking,Off
Property,COM7,Parity,None
Property,COM7,StopBits,1
Property,COM7,Verbose,1
Property,COM4,AnswerTimeout,500.0000
Property,COM4,BaudRate,115200
Property,COM4,DelayBetweenCharsMs,0.0000
Property,COM4,Handshaking,Off
Property,COM4,Parity,None
Property,COM4,StopBits,1
Property,COM4,Verbose,1
Property,PI_GCSController_Y,Port,COM4
Property,PI_GCSController_Y,um in default unit,0.0010
Property,PI_GCSController_X,Port,COM5
Property,PI_GCSController_X,um in default unit,0.0010
Property,PIXYStage,Axis X: HomingMode,REF
Property,PIXYStage,Axis X: Name,1
Property,PIXYStage,Axis X: Stage,DEFAULT_STAGE
Property,PIXYStage,Axis Y: HomingMode,REF
Property,PIXYStage,Axis Y: Name,1
Property,PIXYStage,Axis Y: Stage,DEFAULT_STAGE
Property,PIXYStage,Controller Name,PI_GCSController_X
Property,PIXYStage,Controller Name for Y axis,PI_GCSController_Y
Property,OlympusHub,Port,COM9
Property,PIZStage,Axis,A
Property,PIZStage,Limit_um,500.0000
Property,PIZStage,Port,COM7

# Pre-init settings for COM ports

# Hub (parent) references

# Initialize
Property,Core,Initialize,1

# Delays

# Focus directions

# Roles
Property,Core,Camera,RetigaR3
Property,Core,Focus,PIZStage
Property,Core,AutoShutter,1

# Camera-synchronized devices

# Labels
# Objective
Label,Objective,4,x 100
Label,Objective,3,x 50
Label,Objective,2,x 20
Label,Objective,1,x 10
Label,Objective,0,x 5
# ReflectedLamp
Label,ReflectedLamp,1,On
Label,ReflectedLamp,0,Off

# Configuration presets
# Group: Objective
# Preset: x 10
ConfigGroup,Objective,x 10,Objective,Label,x 10

# Preset: x 100
ConfigGroup,Objective,x 100,Objective,Label,x 100

# Preset: x 5
ConfigGroup,Objective,x 5,Objective,Label,x 5

# Preset: x 20
ConfigGroup,Objective,x 20,Objective,Label,x 20

# Preset: x 50
ConfigGroup,Objective,x 50,Objective,Label,x 50


# Group: System
# Preset: Startup
ConfigGroup,System,Startup,PIXYStage,TransposeMirrorX,0
ConfigGroup,System,Startup,PIXYStage,TransposeMirrorY,1
ConfigGroup,System,Startup,OlympusHub,Control,Manual + Computer
ConfigGroup,System,Startup,OlympusZStage,FarLimit,0.0100
ConfigGroup,System,Startup,OlympusZStage,NearLimit,15000.0000
ConfigGroup,System,Startup,RetigaR3,Color,ON


# Group: Control
# Preset: Computer
ConfigGroup,Control,Computer,OlympusHub,Control,Computer

# Preset: Manual + Computer
ConfigGroup,Control,Manual + Computer,OlympusHub,Control,Manual + Computer


# Group: Light
# Preset: On
ConfigGroup,Light,On,ReflectedLamp,Label,On

# Preset: Off
ConfigGroup,Light,Off,ReflectedLamp,Label,Off


# Group: Exposure
# Preset: NewPreset
ConfigGroup,Exposure,NewPreset,RetigaR3,Exposure,10.0000


# Group: Light-voltage
# Preset: NewPreset
ConfigGroup,Light-voltage,NewPreset,ReflectedLamp,Voltage,12.0000


# Group: CameraColour
# Preset: ON
ConfigGroup,CameraColour,ON,RetigaR3,Color,ON

# Preset: OFF
ConfigGroup,CameraColour,OFF,RetigaR3,Color,OFF



# PixelSize settings
# Resolution preset: x 10
ConfigPixelSize,x 10,Objective,Label,x 10
PixelSize_um,x 10,0.4538

# Resolution preset: x 100
ConfigPixelSize,x 100,Objective,Label,x 100
PixelSize_um,x 100,0.0448

# Resolution preset: x 5
ConfigPixelSize,x 5,Objective,Label,x 5
PixelSize_um,x 5,0.9097

# Resolution preset: x 20
ConfigPixelSize,x 20,Objective,Label,x 20
PixelSize_um,x 20,0.2283

# Resolution preset: x 50
ConfigPixelSize,x 50,Objective,Label,x 50
PixelSize_um,x 50,0.0906


The full configuration often will take 1 to 60 seconds to complete a simple GUI button click such as changing the objective of the microscope. Whereas using the most basic configuration which uses only the BX61 the same button click will take no more than 1 to 2 seconds at most (often completed in less than 1 second) I have found this to be consistent across the use of micromanager on two different machines(using the same hardware device configuration) but the behavior was not found when used on another(using the same hardware device configuration) all three machines are comparable in performance. I was wondering if there is anyway to improve the speed and interactivity of the GUI as the full configuration often causes the program to slows down so significantly that it becomes difficult to use. It is also prone to hanging in such a state requiring the program to be shut down thus disrupting acquisition process setup.


From looking at the core logs it would appear that in the case of the configuration setups that are using all the devices required, there are consistent errors in the PI controllers which are associated with COM4 in the example as detailed below.


2018-12-06T15:16:07.954778 tid2200 [dbg,dev:COM4] SetCommand -> JON? 1\n
2018-12-06T15:16:08.454807 tid2200 [IFO,dev:COM4] TERM_TIMEOUT error occured!
2018-12-06T15:16:08.454807 tid2200 [ERR,Core] Error occurred in device COM4: Error in device "COM4": (Error message unavailable) (107)
2018-12-06T15:16:08.454807 tid2200 [dbg,dev:COM4] SetCommand -> ERR?\n
2018-12-06T15:16:08.466807 tid2200 [dbg,dev:COM4] GetAnswer <- 2\n
2018-12-06T15:16:08.466807 tid2200 [dbg,dev:COM4] SetCommand -> TPC?\n
2018-12-06T15:16:08.966836 tid2200 [IFO,dev:COM4] TERM_TIMEOUT error occured!
2018-12-06T15:16:08.966836 tid2200 [ERR,Core] Error occurred in device COM4: Error in device "COM4": (Error message unavailable) (107)
2018-12-06T15:16:08.966836 tid2200 [dbg,dev:COM4] SetCommand -> ERR?\n

These errors are not found when a basic/reduced config is used would this be a possible source of the errors?

From further investigation in the core logs it appears that in the instances when the full configuration is used that much of delays experienced are reported as fetch response timeouts as shown below.

2018-12-06T16:01:46.436782 tid5660 [dbg,dev:Objective] FetchResponse
2018-12-06T16:01:46.636794 tid5660 [IFO,dev:Objective] FetchResponse-Timeout(1OB)
2018-12-06T16:01:46.636794 tid5660 [dbg,dev:Objective] FetchResponse
2018-12-06T16:01:46.637794 tid5660 [IFO,dev:Objective] FetchResponse-Timeout()
2018-12-06T16:01:46.647794 tid5660 [dbg,dev:Objective] FetchResponse
2018-12-06T16:01:46.648794 tid5660 [IFO,dev:Objective] FetchResponse-Timeout()
2018-12-06T16:01:46.658795 tid5660 [dbg,dev:Objective] FetchResponse
2018-12-06T16:01:46.659795 tid5660 [IFO,dev:Objective] FetchResponse-Timeout()
2018-12-06T16:01:46.669796 tid5660 [dbg,dev:Objective] FetchResponse
2018-12-06T16:01:46.670796 tid5660 [IFO,dev:Objective] FetchResponse-Timeout()
2018-12-06T16:01:46.680796 tid5660 [dbg,dev:Objective] FetchResponse
2018-12-06T16:01:46.681796 tid5660 [IFO,dev:Objective] FetchResponse-Timeout()
2018-12-06T16:01:46.691797 tid5660 [dbg,dev:Objective] FetchResponse

For the example as previously given of clicking the objective change button these events were logged repeatedly for 60 seconds. In contrast far fewer of these events are logged when a configuration that uses less devices and does not have the associated COM port errors is used. My thoughts are that there seam to be associated timeouts that increase in quantity as more devices are configured, the errors in the PI controllers also may be contributing. I would appreciate any advice and help regarding the issues raised, please ask if more information is required or if anything is unclear.

Thanks,

Conor




_______________________________________________
micro-manager-general mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/micro-manager-general
Reply | Threaded
Open this post in threaded view
|

Re: Slow down of

Stuurman, Nico
Hi Conor,


On 12/6/18 8:35 AM, C.N.McMurray wrote:
> I have been experiencing significant delays in the interaction with
> the micromanager GUI. The delays seem to be exacerbated when more
> devices are installed in a given configuration and reduced if devices
> are removed form the configuration.

> From looking at the core logs it would appear that in the case of the
> configuration setups that are using all the devices required, there
> are consistent errors in the PI controllers which are associated with
> COM4 in the example as detailed below.
>
>
> 2018-12-06T15:16:07.954778 tid2200 [dbg,dev:COM4] SetCommand -> JON? 1\n
> 2018-12-06T15:16:08.454807 tid2200 [IFO,dev:COM4] TERM_TIMEOUT error
> occured!
> 2018-12-06T15:16:08.454807 tid2200 [ERR,Core] Error occurred in device
> COM4: Error in device "COM4": (Error message unavailable) (107)


I would first track down and fix these communication issues.  It seems
that your PI controller does not respond.  Does it work at all?  Each
communication with the controller that leads to this error will add a
delay of 500 ms (actually, you can set how long the serial port will
wait for an answer as a serial port property), so it is easy to see how
this will add up to many seconds of delay. Clearly, there is some kind
of problem with the configuration (are the serial port settings for this
device correct?), the device, or the device adapter. You can check how
much this contributes to the delays you see by making a full
configuration without the PI controller.

Best,


Nico





_______________________________________________
micro-manager-general mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/micro-manager-general
Reply | Threaded
Open this post in threaded view
|

Re: Slow down of

C.N.McMurray

Hi Nico


The PI controller definitely works but these errors are always present


COM4: Error in device "COM4": (Error message unavailable) (107)


we have also made full configurations without the PI controller and we still observe some slowness in the GUI although it is less of a delay.


I will look at reducing the delays via changing serial port properties but Im not sure how to trace the cause of the errors as the error message is always unavailable


Thanks very much for the help


Best,


Conor


From: Stuurman, Nico <[hidden email]>
Sent: 06 December 2018 17:54:04
To: Micro-Manager General
Subject: Re: [micro-manager-general] Slow down of
 
Hi Conor,


On 12/6/18 8:35 AM, C.N.McMurray wrote:
> I have been experiencing significant delays in the interaction with
> the micromanager GUI. The delays seem to be exacerbated when more
> devices are installed in a given configuration and reduced if devices
> are removed form the configuration.

> From looking at the core logs it would appear that in the case of the
> configuration setups that are using all the devices required, there
> are consistent errors in the PI controllers which are associated with
> COM4 in the example as detailed below.
>
>
> 2018-12-06T15:16:07.954778 tid2200 [dbg,dev:COM4] SetCommand -> JON? 1\n
> 2018-12-06T15:16:08.454807 tid2200 [IFO,dev:COM4] TERM_TIMEOUT error
> occured!
> 2018-12-06T15:16:08.454807 tid2200 [ERR,Core] Error occurred in device
> COM4: Error in device "COM4": (Error message unavailable) (107)


I would first track down and fix these communication issues.  It seems
that your PI controller does not respond.  Does it work at all?  Each
communication with the controller that leads to this error will add a
delay of 500 ms (actually, you can set how long the serial port will
wait for an answer as a serial port property), so it is easy to see how
this will add up to many seconds of delay. Clearly, there is some kind
of problem with the configuration (are the serial port settings for this
device correct?), the device, or the device adapter. You can check how
much this contributes to the delays you see by making a full
configuration without the PI controller.

Best,


Nico





_______________________________________________
micro-manager-general mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/micro-manager-general



_______________________________________________
micro-manager-general mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/micro-manager-general