Projects
mass
turbina-core-dimm
Log In
Username
Password
We truncated the diff of some files because they were too big. If you want to see the full diff for every file,
click here
.
Overview
Repositories
Revisions
Requests
Users
Attributes
Meta
Expand all
Collapse all
Changes of Revision 4
View file
turbina-core-dimm.spec
Changed
@@ -1,7 +1,7 @@ # -# spec file for package turbina-core-dimm (Version 2.40) +# spec file for package turbina-core-dimm (Version 2.45) # -# Copyright (c) 2010 Matwey V. Kornilov. +# Copyright (c) 2012 Matwey V. Kornilov. # This file and all modifications and additions to the pristine # package are under the same license as the package itself. # @@ -32,7 +32,7 @@ BuildRequires: make gcc gcc-c++ libdc1394-devel boost-devel Summary: DIMM measure daemon Name: turbina-core-dimm -Version: 2.40 +Version: 2.45 Release: 1 Source: %{tarname}-%{version}.tar.bz2 Source1: defnames.h @@ -144,5 +144,7 @@ %attr(644,root,root) %{_datadir}/preat/spectra/*.sp %changelog +* Fri Sep 07 2012 - matwey.kornilov@gmail.com +- version 2.45 * Wed Oct 27 2010 - matwey.kornilov@gmail.com - initial version
View file
dimm_tool-2.40.tar.bz2/Makefile -> dimm_tool-2.45.tar.bz2/Makefile
Changed
@@ -10,7 +10,7 @@ DIMM_SOURCES = main.o comms.o dimm.o modes.o find.o frame_proc.o camera.o iidc.o functions.o results.o client_handler.o server.o socket.o astrotime.o configs.o errlog.o PREAT = preat PREAT_SOURCES = preat.o parameter_set.o processing.o coordinates.o astrotime.o -VERSION = 2.40 +VERSION = 2.45 CXX = g++ INSTALL_PROGRAM = install CXXFLAGS += -Wall -O2 -DVERSION=\"$(VERSION)\" -I./infras -I./server
View file
dimm_tool-2.40.tar.bz2/camera.cpp -> dimm_tool-2.45.tar.bz2/camera.cpp
Changed
@@ -68,6 +68,7 @@ } Record::Record( Camera* cam, win<int> w ){ + int nbuffs = 8000000/w.xdim()*w.ydim(); try { frame = std::auto_ptr<Fprocess>(new Fprocess( w - w.beg() )); if( (cam->ieeecam).get() ) { @@ -75,7 +76,7 @@ (cam->ieeecam)->setFormat7ImageROI( w.xorg(), w.yorg(), w.xdim(), w.ydim() ); current_win = w; } - (cam->ieeecam)->setupCapture( 20 ); + (cam->ieeecam)->setupCapture( nbuffs ); stream = std::auto_ptr<IIDC::VideoStream<unsigned short> >(new IIDC::VideoStream<unsigned short>( (cam->ieeecam).get() )); } the = cam;
View file
dimm_tool-2.40.tar.bz2/camera.h -> dimm_tool-2.45.tar.bz2/camera.h
Changed
@@ -1,7 +1,7 @@ #ifndef _CAMERA_H #define _CAMERA_H #include <string> -//#include <unistd.h> +#include <unistd.h> // for swab #include <configs.h> #include <memory>
View file
dimm_tool-2.40.tar.bz2/defnames.h -> dimm_tool-2.45.tar.bz2/defnames.h
Changed
@@ -1,8 +1,8 @@ #ifndef _DEFNAMES_H #define _DEFNAMES_H -const std::string program_root = "./"; // äÌÑ ÏÔÌÁÄËÉ -//const std::string program_root = "/opt/dimm/"; // óÔÁÎÄÁÒÔÎÏÅ ÍÅÓÔÏ +//const std::string program_root = "./"; // For debug +const std::string program_root = "/opt/dimm/"; // Standard location const std::string program_etc = program_root + "etc/"; const std::string program_res = program_root + "data/out/";
View file
dimm_tool-2.40.tar.bz2/etc/turdimm.cfg -> dimm_tool-2.45.tar.bz2/etc/turdimm.cfg
Changed
@@ -17,16 +17,16 @@ FrameRate 0 ;working framerate BaseTime 1 ;base time in sec. AccumTime 60 ;accumulation time in sec. - MeasBoxSide 60 ;measuring subframe size, x,y, pxs + MeasBoxSide 40 ;measuring subframe size, x,y, pxs StarRadius 7 ;image radius for GC calculation, px ThresholdFactor 4 ;in sigma level -# CGMethod window ;or threshold - CG computation method - CGMethod threshold ;or threshold - CG computation method +# CGMethod window ;or threshold - CG computation method + CGMethod threshold ;or threshold - CG computation method MaxDropped 50 ; maximal number of the bad frames EndSubSection SubSection "Centering" Exposure 4.0 ;frame exposure in ms (>=1) - FrameRate 30 ;working framerate + FrameRate 100 ;working framerate AccumTime 2 ;full time of the centering phase ThresholdFactor 6 ;in sigma level MinObjectFlux 300 ;min total flux for target images @@ -54,7 +54,7 @@ FieldAperture 184 ;radius of the field diaphragm, px Scale 0.634 ;frame scale, arcsec/px FocalCoeff 200 ; connection to focal changeing - Separation 35.5 ; preferable images separation + Separation 30 ; preferable images separation OpticalCenter 334 215 ;optical center position on the frame, px EndSubSection SubSection "Type"
View file
dimm_tool-2.40.tar.bz2/find.cpp -> dimm_tool-2.45.tar.bz2/find.cpp
Changed
@@ -349,7 +349,7 @@ for( int y = yb; y < ye; y++ ) { ipix = image->startx+xsize*y; if( ipix < thres ) continue; - ipix -= thres; + ipix -= back; dx = x + 0.5 - xcen; dy = y + 0.5 - ycen; xtot += ipix*dx*dx; ytot += ipix*dy*dy;
View file
dimm_tool-2.40.tar.bz2/frame_proc.cpp -> dimm_tool-2.45.tar.bz2/frame_proc.cpp
Changed
@@ -13,10 +13,30 @@ #include "frame_proc.h" +point<double> Stat::backgr_masked( Sframe *buff, win<int> & wnd, spot& l_blind, spot& r_blind, int size ) { + double v = 0.0, ar = 0.0; + double m = 0.0, s = 0.0; + win<int> wtmp = wnd & win<int>( 0, 0, buff->x, buff->y ); + int xsize = buff->x; + if( wtmp.empty() ) throw ErrFat ( ERR_NORM_EMPTY, "Singular background box" ); + for( int x = wtmp.beg().x(); x < wtmp.end().x(); x++ ) { + for( int y = wtmp.beg().y(); y < wtmp.end().y(); y++ ) { + if( std::abs( x - l_blind.pos().x()) < size && std::abs( y - l_blind.pos().y()) < size ) continue; + if( std::abs( x - r_blind.pos().x()) < size && std::abs( y - r_blind.pos().y()) < size ) continue; + v = *((signed short*)buff->start + x + xsize*y); + m += v; + s += v*v; + ar += 1.0; + } + } + if( ar == 0.0 ) throw ErrFat ( ERR_NORM_EMPTY, "Empty background box" ); + return point<double>( m/ar, s/ar - m*m/ar/ar ); +} + point<double> Stat::backgr( Sframe *buff, std::vector< win<int> >& wnd ) { double v = 0.0, ar = 0.0; double m = 0.0, s = 0.0; - win<int> wimg( 0, 0, buff->x, buff->y ); + win<int> wimg( 0, 0, buff->x, buff->y ); win<int> wtmp; int xsize = buff->x; for( unsigned int i = 0; i < wnd.size(); i++ ) { @@ -35,12 +55,11 @@ return point<double>( m/ar, s/ar - m*m/ar/ar ); } - point<double> Stat::chessboard( Sframe *buff, win<int>& ccd ) { std::vector< win<int> > subw; std::vector<double> vbias; std::vector<double> vnoise; - int cell = 40; + int cell = 10; point<double> tmp; for( int x = 0; x < ccd.xdim()/cell; x++ ) { for( int y = 0; y < ccd.ydim()/cell; y++ ) { @@ -51,7 +70,7 @@ subw.clear(); } } - std::nth_element( vbias.begin(), vbias.begin()+vbias.size()/2, vbias.end() ); + std::nth_element( vbias.begin(), vbias.begin()+vbias.size()/2, vbias.end() ); std::nth_element( vnoise.begin(), vnoise.begin()+vnoise.size()/2, vnoise.end() ); return point<double>( vbias.at(vbias.size()/2), vnoise.at(vnoise.size()/2) ); }
View file
dimm_tool-2.40.tar.bz2/frame_proc.h -> dimm_tool-2.45.tar.bz2/frame_proc.h
Changed
@@ -2,6 +2,7 @@ #define _FPROC_H #include <queue> +#include <numeric> #include "deftypes.h" //#include "find.h" @@ -17,6 +18,7 @@ }; namespace Stat { + point<double> backgr_masked( Sframe *, win<int> & wnd, spot& l_blind, spot& r_blind, int size ); point<double> backgr( Sframe*, std::vector< win<int> >& ); point<double> chessboard( Sframe*, win<int>& ); point<double> black_white( Sframe*, win<int>& ); @@ -63,7 +65,7 @@ } return sum/rq.size(); } - T ask() { return sum/rq.size(); } + T get() { return sum/rq.size(); } }; }
View file
dimm_tool-2.40.tar.bz2/functions.cpp -> dimm_tool-2.45.tar.bz2/functions.cpp
Changed
@@ -66,9 +66,9 @@ #define STARRD sqrt(1.4) #define SIGD (STARRD*sqrt(2.0)) #define GAIN 2.00 -#define SEEING 0.5 +#define SEEING 0 #define YS 0.0 -#define FLUX 20000 +#define FLUX 2000 //short mask = 0xffff; //0xfffd ÄÌÑ ÂÉÔÏÇÏ 1-ÏÇÏ ÒÁÚÒÑÄÁ
View file
dimm_tool-2.40.tar.bz2/infras/exchange.cpp -> dimm_tool-2.45.tar.bz2/infras/exchange.cpp
Changed
@@ -15,6 +15,8 @@ #include <rserrno.h> #include <exchange.h> +#include <unistd.h> // write, usleep, close + const int MAXRETRY = 2; // Maximal number of transaction attempts const int MAX_PACKET_SIZE = 32; // Maximal packet size
View file
dimm_tool-2.40.tar.bz2/infras/module.cpp -> dimm_tool-2.45.tar.bz2/infras/module.cpp
Changed
@@ -9,6 +9,8 @@ #include <module.h> #include <errlog.h> +#include <unistd.h> // usleep + //const char LOAD_KEY = 0x3E; //const char READ_KEY = 0xFE;
View file
dimm_tool-2.40.tar.bz2/modes.cpp -> dimm_tool-2.45.tar.bz2/modes.cpp
Changed
@@ -16,7 +16,7 @@ #include "find.h" #include "defnames.h" -const int BGsmooth = 64; +const int BGsmooth = 256; const int XYsmooth = 64; const double spar_time=2.0; @@ -32,6 +32,8 @@ Geometry Mode::focal; point<double> Mode::common = point<double>(); point<double> Mode::differ = point<double>(); +Stat::smooth< point<double> > Mode::background( BGsmooth ); +//point<double> Mode::background = point<double>(); Settings initSettings( Config *cf, const std::string& from ) { Settings tmp; @@ -78,11 +80,11 @@ void Center::measure() { break_mode = false; - Stat::smooth< point<double> > backgr(BGsmooth); +// Stat::smooth< point<double> > backgr(BGsmooth); std::vector<spot> mark_spots; std::vector<spot> L_spots; std::vector<spot> R_spots; - std::vector< win<int> > ovl; +// std::vector< win<int> > ovl; Sframe image; point<int> rap( (int)rint(focal.field+0.5*focal.separation), (int)rint(focal.field) ); point<int> oax = focal.optic_axis; @@ -90,15 +92,15 @@ cam->setParameters( camera ); Timer timer( accumtime+spar_time ); int nframe = (int)rint( accumtime*cam->effFPS(camera)); - cent_win &= cam->ccdFormat(); // Limit window by CCD format - Record camrec( cam, cent_win ); // Window against CCD - ovl.push_back( cent_win - cent_win.beg() ); // Window against image + cent_win &= cam->ccdFormat(); // Limit window by CCD format + Record camrec( cam, cent_win ); // Window against CCD + win<int> cent_image = cent_win - cent_win.beg(); // Window against image double acquis_end = utc.currentSec() + accumtime - 0.001*camera.exposure; for( nframe = 0; utc.currentSec() < acquis_end && !timer.out() && !break_mode ; nframe++ ) { image = camrec.getFrame(); - bias = backgr.add( Stat::chessboard( &image, ovl0 ) ); - if( Proc::spots_find( &image, ovl0, bias.mean()+threshold*sqrt(bias.vars()), mark_spots ) > 1 ){ + bias = background.add( Stat::chessboard( &image, cent_image ) ); + if( Proc::spots_find( &image, cent_image, bias.mean()+threshold*sqrt(bias.vars()), mark_spots ) > 1 ){ std::partial_sort( mark_spots.begin(), mark_spots.begin()+2, mark_spots.end(), Proc::brighter ); if( mark_spots1.sum() < minflux ) continue; int left = ( mark_spots0.pos().x() < mark_spots1.pos().x() )? 0 : 1; @@ -151,28 +153,38 @@ } bool Normal::check_bound( int nf, spot& le, spot& re ){ - std::string bound_side; +/* std::string bound_side; if( le.pos().x() < stars_box.beg().x() + radius ) bound_side = " ~LB"; if( re.pos().x() > stars_box.end().x() - radius ) bound_side = " ~RB"; if( min( le.pos().y(), re.pos().y()) < stars_box.beg().y() + radius ) bound_side = " ~BB"; if( max( le.pos().y(), re.pos().y()) > stars_box.end().y() - radius ) bound_side = " ~UB"; bool alert = !bound_side.empty(); - if( alert ) ErrlogSingl::instance().warning( out->wrongData( nf, bound_side, (star&)le, (star&)re )); + if( alert ) ErrlogSingl::instance().warning( out->wrongData( nf, bound_side, (star&)le, (star&)re ));*/ + bool alert = false; + if( le.pos().x() < stars_box.beg().x() + radius ) alert = true; + if( re.pos().x() > stars_box.end().x() - radius ) alert = true; + if( min( le.pos().y(), re.pos().y()) < stars_box.beg().y() + radius ) alert = true; + if( max( le.pos().y(), re.pos().y()) > stars_box.end().y() - radius ) alert = true; return alert; } bool Normal::check_separ( int nf, spot& L, spot& R, int sep ){ - std::string bound_side; +/* std::string bound_side; if( R.pos().x() - L.pos().x() < sep - 2*radius ) bound_side = " <SP"; if( R.pos().x() - L.pos().x() > sep + 2*radius ) bound_side = " >SP"; bool alert = !bound_side.empty(); - if( alert ) ErrlogSingl::instance().warning( out->wrongData( nf, bound_side, (star&)L, (star&)R ) ); - return alert; + if( alert ) ErrlogSingl::instance().warning( out->wrongData( nf, bound_side, (star&)L, (star&)R ) );*/ +// bool alert = false; +// if( R.pos().x() - L.pos().x() < sep - 2*radius ) alert = true; +// if( R.pos().x() - L.pos().x() > sep + 2*radius ) alert = true; +// return alert; +// double diffs = R.pos().x() - L.pos().x() - sep; +// return (( diffs < -2*radius )||( diffs > 2*radius ))? true : false; + return ( std::abs(R.pos().x() - L.pos().x() - sep ) > 2*radius ) ? true : false; } void Normal::measure() { break_mode = false; - Stat::smooth< point<double> > backgr(BGsmooth); Stat::Accum L; Stat::Accum R; star L_current; @@ -181,25 +193,24 @@ star R_vars, R_covs; std::vector<spot> mark_spots; out->outmode( name ); - if( 2*max(cent->stars_radius().x(),cent->stars_radius().y()) > radius ) + if( 2*max( cent->stars_radius().x(), cent->stars_radius().y()) > radius ) ErrlogSingl::instance().warning( "Star aperture radius is too small", radius ); Sframe image; Timer timer( accumtime+spar_time ); cam->setParameters( camera ); - int nframe = (int)rint( basetime*cam->effFPS(camera)); + int nframe = (int)rint( basetime*cam->effFPS( camera ) ); std::vector<star> L_spots; std::vector<star> R_spots; L_spots.reserve(nframe); R_spots.reserve(nframe); - std::vector< win<int> > wback; int V_size = box_yside/2; int separation_x = (int)separation().x(); - int H_size = box_yside + separation_x/2; +// int H_size = box_yside + separation_x/2; + int H_size = box_yside/2 + separation_x/2; win<int> ccd_box( -H_size, -V_size, H_size, V_size ); // This window against CCD - wback.push_back( win<int>( 0, 0, V_size, 2*V_size ) ); // Three windows into ccd_box - wback.push_back( win<int>( 2*H_size-V_size, 0, 2*H_size, 2*V_size ) ); - stars_box = win<int>( V_size, 0, 2*H_size - V_size, 2*V_size ); - double acquis_end = utc.currentSec() + basetime; +// stars_box = win<int>( V_size, 0, 2*H_size - V_size, 2*V_size ); + stars_box = win<int>( 0, 0, 2*H_size, 2*V_size ); + double acquis_end = utc.currentSec() + basetime; for( int i = 0; i < accumtime/basetime && !timer.out() && !break_mode; i++){ win<int> wbox = ccd_box + common; if( common.distance(focal.optic_axis) > 0.5*focal.field ) @@ -212,11 +223,11 @@ int fskipped = 0; for( nframe = 0; utc.currentSec() < acquis_end && !timer.out(); nframe++ ) { image = camrec.getFrame(); - bias = backgr.add( Stat::backgr( &image, wback ) ); // Background determination - // Finding in working window + bias = background.get(); // Previous background are usedd + // Finding in working window if( Proc::spots_find( &image, stars_box, bias.mean()+threshold*sqrt(bias.vars()), mark_spots ) < 2 ){ if( fskipped++ > maxdrop ) { - int nn = L.exec() + R.exec(); // Output if accumulate is not whole + int nn = L.exec() + R.exec(); // Output if accumulate is not whole out->dimmData( -nn/2, L.mean(), R.mean(), L.vars(), R.vars(), R.covs(), bias ); throw ErrFat ( ERR_NORM_EMPTY, "No two star images" ); } @@ -224,34 +235,36 @@ std::partial_sort( mark_spots.begin(), mark_spots.begin()+2, mark_spots.end(), Proc::brighter ); // if( mark_spots1.sum < minflux ) continue; int left = ( mark_spots0.pos().x() < mark_spots1.pos().x() )? 0 : 1; - // Check with respect to window borders + // Check with respect to window borders bool bound_alert = check_bound( nframe, mark_spotsleft, mark_spots1-left ); if( check_separ( nframe, mark_spotsleft, mark_spots1-left, separation_x ) ) continue; + // Background determination + bias = background.add( Stat::backgr_masked( &image, stars_box, mark_spotsleft, mark_spots1-left, radius ) ); Proc::gravcenter( &image, method, bias, cam->getGain(), radius, mark_spots left , L_current ); Proc::gravcenter( &image, method, bias, cam->getGain(), radius, mark_spots1-left, R_current ); - // Coordinates conertion - the right is difference + // Coordinates conertion - the right is difference if( submode == 1 ) out->rawData( nframe, L_current, R_current ); R_current.set( R_current.pos() - L_current.pos() ); L_current.set( L_current.pos() + R_current.pos()/2.0 ); - L_current.set( L_current.pos() + wbox.beg() ); // ROI transformation to CCD coordinates - if( !bound_alert ) { // If no problems add to vector + L_current.set( L_current.pos() + wbox.beg() ); // ROI transformation to CCD coordinates + if( !bound_alert ) { // If no problems add to vector L_spots.push_back(L_current); R_spots.push_back(R_current); } } } out->writeFrame( &image, program_img + "boxframe.fits" ); - int nf = Stat::moments( L_spots, L_star, L_vars, L_covs ) - + Stat::moments( R_spots, R_star, R_vars, R_covs ); + int nf = Stat::moments( L_spots, L_star, L_vars, L_covs ) + Stat::moments( R_spots, R_star, R_vars, R_covs ); L_spots.clear(); R_spots.clear(); if( nf == 0 ) throw ErrFat ( ERR_NORM_EMPTY, "Empty basetime set" ); - common = L_star.pos(); // Average over basetime - differ = R_star.pos(); // Average over basetime + if( nf/2 != nframe ) ErrlogSingl::instance().warning( "Lost frames ", nframe-nf/2 ); + common = L_star.pos(); // Average over basetime + differ = R_star.pos(); // Average over basetime L_star.set( L_star.pos() - focal.optic_axis ); - // Results output function + // Results output function out->dimmData( nf/2, L_star, R_star, L_vars, R_vars, R_covs, bias ); - L.add( L_star, L_vars, L_covs ); // For average over accumtime + L.add( L_star, L_vars, L_covs ); // For average over accumtime R.add( R_star, R_vars, R_covs ); acquis_end += basetime; } @@ -261,7 +274,7 @@ Estimation::Estimation( Config& cf, Camera &cm, Center &modcen ) : Normal( cf, cm, modcen ) { name = subs_estim; - basetime = 5*cfg->inp<int>( sect_operation, subs_normal, "BaseTime" ); + basetime = cfg->inp<int>( sect_operation, subs_normal, "BaseTime" ); accumtime = 5*cfg->inp<int>( sect_operation, subs_normal, "BaseTime" );
View file
dimm_tool-2.40.tar.bz2/modes.h -> dimm_tool-2.45.tar.bz2/modes.h
Changed
@@ -5,7 +5,7 @@ #include <configs.h> #include <sys/time.h> #include <server.h> - +#include "frame_proc.h" #include "deftypes.h" class Result; @@ -20,6 +20,8 @@ static Geometry focal; static point<double> common; static point<double> differ; + static Stat::smooth< point<double> > background; +// static point<double> background; std::string name; bool break_mode; int accumtime;
View file
dimm_tool-2.40.tar.bz2/processing.cpp -> dimm_tool-2.45.tar.bz2/processing.cpp
Changed
@@ -97,6 +97,7 @@ vars(1) = vars(1)*vars(1) - vars(3)*vars(3); // CCD noise removal double rho = vars(2)/vars(1); vars(1) = 1.15*vars(1) - 0.15*vars(2); // exposure correction +// vars(1) = vars(1); // exposure correction vars(2) = rho; } @@ -120,6 +121,10 @@ lmotion.push_back( lm ); vector< double > tm = vector_slice< vector<double> >( dmotion, ts ); corrections( tm ); +/* double rat = (1.0 - tm(2))/(1.0 - lm(2)); + tm(2) = (tm(1)*tm(2)+lm(1)*lm(2))/(tm(1)+lm(1)); + lm(2) = rat; + lmotion.push_back( lm );*/ tmotion.push_back( tm ); nframes.push_back( nfr ); }
View file
dimm_tool-2.40.tar.bz2/results.cpp -> dimm_tool-2.45.tar.bz2/results.cpp
Changed
@@ -67,9 +67,7 @@ } file.clear(); if( append ) file.close(); -/* atmosIP = IP4Addr( cf.inp<std::string>( sect_operation, subs_guide, "SensorHost"), - cf.inp<unsigned int>( sect_operation, subs_guide, "SensorPort") );*/ - try { +/* try { process_online = false; ClientSocket::AddrType atmosIP = IP4Addr( "localhost", 16000 ); atmos = std::auto_ptr<ClientHandler>( new ClientHandler( atmosIP ) ); @@ -77,7 +75,7 @@ } catch(const std::exception& e ) { ErrlogSingl::instance().write( std::string("Processing: ") + e.what() ); - } + }*/ file.open( filename.c_str(), std::ios::out | std::ios::app ); if( !file ) throw ErrFat( (ErrorsCode)errno, filename ); file << comstamp() << progname << VERSION << " Compiled " << __TIME__ << " " << __DATE__<< std::endl; @@ -88,7 +86,7 @@ std::string newpstr = parstamp() + (&cfg)->Pstr(i); std::ostringstream padd( newpstr ); file << padd; - if( process_online ) atmos->out( newpstr ); +// if( process_online ) atmos->out( newpstr ); } } rPs.clear(); @@ -125,35 +123,35 @@ if( n == 0 ) return; std::ostringstream outstr; outstr << headstamp( ( n < 0 )? "D" : "d" ) << fixed << setw(4) << abs(n) - // ðÏÌÎÙÊ ÐÏÔÏË - ÍÏÖÅÔ ÚÁÎÉÍÁÔØ ÂÏÌØÛÅ ÄÌÑ 12 ÂÉÔ + // Fluxes integrated above background << setprecision(0) << setw(6) << mc.sum() << setw(6) << md.sum() - // ïÔÎÏÓÉÔÅÌØÎÙÅ óëï ÐÏÌÎÏÇÏ ÐÏÔÏËÁ + // Relative standard deviations of the fluxes << setprecision(3) << setw(7) << sqrt(dc.sum())/mc.sum() << setw(7) << sqrt(dd.sum())/md.sum() - // íÁËÓÉÍÁÌØÎÙÊ ÐÏÔÏË - ÍÏÖÅÔ ÚÁÎÉÍÁÔØ ÂÏÌØÛÅ ÄÌÑ 12 ÂÉÔ + // Maximal intensity << setprecision(0) << setw(5) << mc.max() << setw(5) << md.max() - // òÁÚÎÏÓÔØ ãô ÐÏ x É ÐÏ y + // Differences of GC positions on x and y << setprecision(2) << setw(7) << md.pos().x() << setw(7) << md.pos().y() - // óëï ÒÁÚÎÏÓÔÉ ãô ÐÏ x É ÐÏ y + // Standard deviations of these differences << setprecision(3) << setw(7) << sqrt(dd.pos().x()) << setw(7) << sqrt(dd.pos().y()) - // ACF(1) ÒÁÚÎÏÓÔÉ ãô ÐÏ x É ÐÏ y + // Covarince of GC positions on x and y << setprecision(3) << setw(7) << cv.pos().x() << setw(7) << cv.pos().y() - // óëï ×ËÌÁÄÁ ÛÕÍÁ × ÒÁÚÎÏÓÔÉ ãô ÐÏ x É ÐÏ y + // Standard deviations of noise inpact << setw(7) << sqrt(mc.err().x()+md.err().x()) << setw(7) << sqrt(mc.err().y()+md.err().y()) - // ëÏÏÒÄÉÎÁÔÙ ÃÅÎÔÒÁ ÉÚÏÂÒÁÖÅÎÉÊ ÏÔÎÏÓÉÔÅÌØÎÏ ïã + // Position of images center with respect to OC << setprecision(1) << setw(7) << mc.pos().x() << setw(7) << mc.pos().y() - // óëï ËÏÏÒÄÉÎÁÔ ÃÅÎÔÒÁ + // Standard deviations of these position << setprecision(2) << setw(7) << sqrt(dc.pos().x()) << setw(7) << sqrt(dc.pos().y()) - // óë ÒÁÄÉÕÓ ÌÅ×ÏÇÏ ÉÚÏÂÒÁÖÅÎÉÑ + // Mean squared radius of the left image // << setw(7) << sqrt(0.5*(mc.rad().x() + mc.rad().y())) << setw(7) << sqrt( mc.rad().x() + mc.rad().y() ) - // üÌÌÉÐÔÉÞÎÏÓÔØ ÌÅ×ÏÇÏ ÉÚÏÂÒÁÖÅÎÉÑ + // Ellipticity of the left image << setw(7) << (mc.rad().x()-mc.rad().y())/(mc.rad().x()+mc.rad().y()) - // óë ÒÁÄÉÕÓ ÐÒÁ×ÏÇÏ ÉÚÏÂÒÁÖÅÎÉÑ + // Mean squared radius of the right image // << setw(7) << sqrt(0.5*(md.rad().x() + md.rad().y())) << setw(7) << sqrt( md.rad().x() + md.rad().y() ) - // üÌÌÉÐÔÉÞÎÏÓÔØ ÐÒÁ×ÏÇÏ ÉÚÏÂÒÁÖÅÎÉÑ + // Ellipticity of the right image << setw(7) << (md.rad().x()-md.rad().y())/(md.rad().x()+md.rad().y()) - // ðÏÄÌÏÖËÁ É ÛÕÍ ÐÏÄÌÏÖËÉ × ADU + // Bias and noise ADU << setw(7) << bias.mean() << setw(7) << sqrt(bias.vars()); file << outstr; if( process_online ) atmos->out( outstr.str() );
View file
dimm_tool-2.40.tar.bz2/server/server.cpp -> dimm_tool-2.45.tar.bz2/server/server.cpp
Changed
@@ -81,8 +81,7 @@ cbtable_socket.onError = &Client::onSocketError; m_socket = new ClientSocket( &cbtable_socket, this ); m_socket->connect(m_addr); - sem_init( &this->client_sem, 0, 0 ); -// std::cerr << "sem wait connect" << std::endl; + sem_init( &client_sem, 0, 0 ); waitReply( connect_timeout ); // std::cerr << "Client constructor" << std::endl; } @@ -90,7 +89,7 @@ Client::~Client(){ // std::cerr << "Client destructor" << std::endl; delete m_socket; - sem_destroy( &this->client_sem ); + sem_destroy( &client_sem ); } void Client::sendRequest( const std::string& r ) { @@ -118,8 +117,7 @@ if( errno == EINTR ) { ErrlogSingl::instance().warning( "Signal while waiting server reply" ); if( sem_timedwait( &this->client_sem, &locktime ) < 0 ) throw std::runtime_error("Server reply timeout" ); - } - else throw std::runtime_error("Server reply unknown error" ); + } else throw std::runtime_error("Server reply unknown error" ); } }
View file
dimm_tool-2.40.tar.bz2/server/socket.cpp -> dimm_tool-2.45.tar.bz2/server/socket.cpp
Changed
@@ -1,6 +1,6 @@ /* * socket.cpp is a part of programm carbon -* $Id: socket.cpp,v 1.2 2008/01/23 20:41:57 victor Exp $ +* $Id: socket.cpp,v 1.3 2012/07/20 14:40:03 matwey Exp $ * Copyright (C) 2005-2006 Matwey V. Kornilov * * This program is free software; you can redistribute it and/or modify @@ -91,7 +91,7 @@ template <class SocketTraits> BasicClientSocket<SocketTraits>::BasicClientSocket( ServerSocket* serv ){ BasicSocketBase<SocketTraits>::m_pImpl=serv->popAcceptedTraits(); SocketWatcher::instance().addSocket(this); - setState(SocketBase::Connected); + this->setState(SocketBase::Connected); } template <class SocketTraits> BasicClientSocket<SocketTraits>::~BasicClientSocket(){ @@ -110,13 +110,12 @@ template <class SocketTraits> void BasicClientSocket<SocketTraits>::connect( const typename ClientSocket::AddrType& addr ){ BasicSocketBase<SocketTraits>::m_pImpl->connect( addr ); - setState( SocketBase::Connecting ); + this->setState( SocketBase::Connecting ); } template <class SocketTraits> void BasicClientSocket<SocketTraits>::close(){ -// std::cerr << "Socket close " << std::endl; BasicSocketBase<SocketTraits>::m_pImpl->close(); - setState( SocketBase::Idle ); + this->setState( SocketBase::Idle ); } template <class SocketTraits> void BasicClientSocket<SocketTraits>::read(){ @@ -145,13 +144,13 @@ template <class SocketTraits> void BasicServerSocket<SocketTraits>::listen( const typename ServerSocket::AddrType& addr, int backlog ){ BasicSocketBase<SocketTraits>::m_pImpl->bind( addr ); BasicSocketBase<SocketTraits>::m_pImpl->listen( backlog ); - setState( SocketBase::Listening ); + this->setState( SocketBase::Listening ); accept(); } template <class SocketTraits> void BasicServerSocket<SocketTraits>::close(){ BasicSocketBase<SocketTraits>::m_pImpl->close(); - setState( SocketBase::Idle ); + this->setState( SocketBase::Idle ); } template <class SocketTraits> SocketTraits* BasicServerSocket<SocketTraits>::popAcceptedTraits(){
Locations
Projects
Search
Status Monitor
Help
Open Build Service
OBS Manuals
API Documentation
OBS Portal
Reporting a Bug
Contact
Mailing List
Forums
Chat (IRC)
Twitter
Open Build Service (OBS)
is an
openSUSE project
.