Changeset 922ef55 in sasview


Ignore:
Timestamp:
Apr 6, 2017 12:00:22 PM (7 years ago)
Author:
Tim Snow <tim.snow@…>
Branches:
master, ESS_GUI, ESS_GUI_Docs, ESS_GUI_batch_fitting, ESS_GUI_bumps_abstraction, ESS_GUI_iss1116, ESS_GUI_iss879, ESS_GUI_iss959, ESS_GUI_opencl, ESS_GUI_ordering, ESS_GUI_sync_sascalc, magnetic_scatt, release-4.2.2, ticket-1009, ticket-1094-headless, ticket-1242-2d-resolution, ticket-1243, ticket-1249, ticket885, unittest-saveload
Children:
f2cc00b
Parents:
c5c247e
Message:

Quick stash commit

Changing branches

File:
1 edited

Legend:

Unmodified
Added
Removed
  • src/sas/sasgui/perspectives/fitting/basepage.py

    rc5c247e r922ef55  
    17041704        :param chisqr: update chisqr value [bool] 
    17051705        """ 
    1706  
     1706        # Get the time 
    17071707        currentTime = time() 
     1708 
    17081709        # # So, if a whole pile of jobs are submitted in quick succession,  
    17091710        # # let's say in less than 0.1 sec, we'll filter them out, assuming something is running! 
    17101711        if ((self._manager.calc_1D is not None) and self._manager.calc_1D.isrunning()) or ((self._manager.calc_2D is not None) and self._manager.calc_2D.isrunning()): 
    17111712            if currentTime > (self.lastTimeFitSubmitted + 0.1): 
    1712                 self.threadedDrawQueue.put([update_chisqr, source]) 
     1713                # Assuming that things have been 'sensibly' submitted, but there's another 
     1714                # job going, dump the currently queued job and just execute the job requested last 
     1715                if self.threadedDrawQueue.empty() == True: 
     1716                    self.threadedDrawQueue.put([update_chisqr, source]) 
     1717                    print 'here' 
     1718                else: 
     1719                    print 'rejected' 
    17131720        else: 
    17141721            self.threadedDrawQueue.put([update_chisqr, source]) 
     
    17201727            inputVariables = threadedDrawQueue.get() 
    17211728            self._draw_model_after(inputVariables[0], inputVariables[1]) 
    1722             self.threadedDrawQueue.task_done() 
    17231729            wx.PostEvent(self._manager.parent, StatusEvent(status="Computation is in progress...", type = "progress")) 
     1730            threadedDrawQueue.task_done() 
    17241731 
    17251732    def _draw_model_after(self, update_chisqr=True, source='model'): 
Note: See TracChangeset for help on using the changeset viewer.