Search Results

Search found 1607 results on 65 pages for 'daniel stevens'.

Page 39/65 | < Previous Page | 35 36 37 38 39 40 41 42 43 44 45 46  | Next Page >

  • Installing a rails plugin from a Git repository

    - by Daniel Beardsley
    I've been trying to install Shoulda script/plugin install git://github.com/thoughtbot/shoulda.git but all I get is: removing: C:/Documents and Settings/Danny/My Documents/Projects/Ruby On Rails/_ProjectName_/vendor/plugins/shoulda/.git > And the vender/plugins directory is empty. I have Rails 2.1.1 installed as a gem and have verified that 2.1.1 is loaded (using a puts inserted into config/boot.rb). Any ideas about what's going on? (this is on a windows box)

    Read the article

  • If/Then in SQL Embedded in VBA

    - by Daniel
    I've got a string like this in my Excel VBA: strSQL = "SELECT * FROM Total WHERE (SimulationID = (" & TextBox1.Text & ") And Test1 = (" & Example & "))" However, sometimes Test will be 'is null', which makes the query And Example = is NULL How can I change it to add an if/then statement or something to make it say And Example is null when Example has a value of "is null"?

    Read the article

  • What is the equivalent of <composite-element> in Castle ActiveRecord?

    - by Daniel T.
    I have a TrackLog that has a collection of TrackPoints: public class TrackLog { public string Name { get; set; } public ISet<TrackPoint> TrackPoints { get; set; } } public class TrackPoint { public DateTime Timestamp { get; set; } public double Latitude { get; set; } public double Longitude { get; set; } } I'd like to map the track points as a collection of components, as this makes the most sense. According to the book NHibernate in Action, on page 187: Collections of components are mapped similarily to other collections of value type instances. The only difference is the use of <composite-element> in place of the familiar <element> tag. How would I do this using Castle ActiveRecord attributes?

    Read the article

  • How much network overhead does TLS add compared to a non-encrypted connection?

    - by Daniel Sterling
    (Approximately) how many more bits of data must be transferred over the network during an encrypted connection compared to an unencrypted connection? IIUC, once the TLS handshake has completed, the number of bits transferred is equal to those transferred during an unencrypted connection. Is this accurate? As a follow up, is transferring a large file over https significantly slower than transferring that file over http, given fast processors and the same (ideal) network conditions?

    Read the article

  • Visual Basic .NET Help

    - by Daniel
    How can I get this code into a loop? contact.first_name = list.Item(0) contact.middle_name = list.Item(1) contact.last_name = list.Item(2) contact.age = list.Item(3) contact.mobile_phone = list.Item(4) contact.home_phone = list.Item(5) contact.work_phone = list.Item(6) contact.home_street = list.Item(7) contact.home_city = list.Item(8) contact.home_state = list.Item(9) contact.home_zip = list.Item(10) contact.work_street = list.Item(11) contact.work_city = list.Item(12) contact.work_state = list.Item(13) contact.work_zip = list.Item(14)

    Read the article

  • Cannot run texi2dvi on R Ubuntu

    - by João Daniel
    I'm trying to generate a pdf file from a tex file from R, but I'm getting the following error: > tools::texi2dvi("teste.tex",) Error in tools::texi2dvi("teste.tex", ) : Running 'texi2dvi' on 'teste.tex' failed. Messages: sed: can't read ./teste.tex: Permission denied mkdir: cannot create directory `teste.t2d': Permission denied /usr/bin/texi2dvi: cannot create directory: teste.t2d The user owns the file teste.tex and also the folder it's located. I'm running it into Ubuntu 12.04 and R 2.15.0 Does anyone knows what's going on?

    Read the article

  • SVN Import Force for importing existing file

    - by Daniel A. White
    I am creating a text file and a zip file for a tag automatically with MSBuild. My msbuild project is called by cruisecontrol.net. The text file is always going to be latest.txt and the zip file will be (version).zip (so it will be different every time). I do not want to commit these files back to my trunk, so I discovered svn import. On the first time, it works for both. On successive runs, it fails since latest.txt already exists in the repository. Do I need to use svn import --force or something else to get these two files pushed up to my repository?

    Read the article

  • XSLT transformation by grouping based on 3 elements/attributes

    - by Daniel
    This question is related to http://stackoverflow.com/questions/2863202/xslt-1-0-grouping-to-reformat-element-defined-by-date-into-element-defined-by-tas Just to understand more clearly the trick behind. How would the XSLT look like if we were to group by date, task and shift as below: Input XML; <Person> <name>John</name> <date>June12</date> <shift tier=1> <workTime taskID=1>34</workTime> <workTime taskID=2>12</workTime> </shift> <shift tier=2> <workTime taskID=1>3</workTime> </shift> </Person> <Person> <name>John</name> <date>June13</date> <shift tier=1> <workTime taskID=1>21</workTime> <workTime taskID=2>11</workTime> </shift> <shift tier=2> <workTime taskID=1>2</workTime> </shift> </Person> and similarly, the output would be <Person> <name>John</name> <tier>1</tier> <taskID>1</taskID> <workTime> <date>June12</date> <time>34</time> </worTime> <workTime> <date>June13</date> <time>21</time> </worTime> </Person> <Person> <name>John</name> <tier>1</tier> <taskID>2</taskID> <workTime> <date>June12</date> <time>12</time> </worTime> <workTime> <date>June13</date> <time>11</time> </worTime> </Person> <Person> <name>John</name> <tier>2</tier> <taskID>1</taskID> <workTime> <date>June12</date> <time>3</time> </worTime> <workTime> <date>June13</date> <time>2</time> </worTime> </Person>

    Read the article

  • What bugs apply to the different FindBugs reportLevels?

    - by Daniel H
    According to the Ant task, the report level is a low/medium/high setting that would look for bugs of different criticallity levels. However, there isn't anything I could find that explains which of the bugs apply to these different reporting levels. Is there somewhere that provides this, even if it is something I need to look at within the source?

    Read the article

  • Complex queries using Rails query language

    - by Daniel Johnson
    I have a query used for statistical purposes. It breaks down the number of users that have logged-in a given number of times. User has_many installations and installation has a login_count. select total_login as 'logins', count(*) as `users` from (select u.user_id, sum(login_count) as total_login from user u inner join installation i on u.user_id = i.user_id group by u.user_id) g group by total_login; +--------+-------+ | logins | users | +--------+-------+ | 2 | 3 | | 6 | 7 | | 10 | 2 | | 19 | 1 | +--------+-------+ Is there some elegant ActiveRecord style find to obtain this same information? Ideally as a hash collection of logins and users: { 2=>3, 6=>7, ... I know I can use sql directly but wanted to know how this could be solved in rails 3.

    Read the article

  • How to implement a countdown clock on a product launch web page?

    - by Daniel Earwicker
    I'm asking this on behalf of a certain corporation: http://www.microsoft.com/visualstudio/en-us/watch-it-live Things to bear in mind: It's 8:30 AM at different times depending on where you are in the world. For example, where I am, it is already 10 AM, whereas in Redmond it's still only 2 AM. That's probably the main thing, I guess. Can any SO users recommend ways to improve the existing countdown page so that it works correctly for users in any timezone? (Serious question - clearly this is a pit that is easy to fall into!)

    Read the article

  • Interop c# using a "long" from c++

    - by Daniel
    On my System: sizeof(long) in c++ is 4 aka 32bits sizeof(long) in c# is 8 aka 64 bits So in my Interop method declarations I've been substituting c++ longs with c# int's however I get the feeling this isn't safe? Why is a long the same size as an int in c++? And long long is 64bits? What's next a long long long long??

    Read the article

  • Open Office Impress

    - by Daniel Ray
    Hi I have seen that in some question around presentation you suggest using OO Impress for this. I am trying to show multiple presentation in a non fullscreen window, but havent been very successful so far. Ideally I want to be able to move this presentation windows around the screen. I have searched the Open Office forum but the is almost nothing concerning this topic and noone seems to know the answer to my question. Im trying to do this in C#. I would be very thankfull if you can give me some directions, how to do this. Thank you

    Read the article

  • Programmer tendency to preach [closed]

    - by Daniel
    I've run across several SO posts that come across as preachy or condescending. Do pedagogical programmers feel plagued by thoughtless questions? Or, do programmers count self-sufficiency such a virtue that any perceived lack of ambition merits scolding? These are some theories, admittedly negative ones. Can anyone offer some insight?

    Read the article

  • Have an unprivileged non-account user ssh into another box?

    - by Daniel Quinn
    I know how to get a user to ssh into another box with a key: ssh -l targetuser -i path/to/key targethost But what about non-account users like apache? As this user doesn't have a home directory to which it can write a .ssh directory, the whole thing keeps failing with: $ sudo -u apache ssh -o StrictHostKeyChecking=no -l targetuser -i path/to/key targethost Could not create directory '/var/www/.ssh'. Warning: Permanently added '<hostname>' (RSA) to the list of known hosts. Permission denied (publickey). I've tried variations using -o UserKnownHostsFile=/dev/null and setting $HOME to /dev/null and none of these have done the trick. I understand that sudo could probably fix this for me, but I'm trying to avoid having to require a manual server config since this code will be deployed on a number of different environments. Any ideas? Here's a few examples of what I've tried that don't work: $ sudo -u apache export HOME=path/to/apache/writable/dir/ ssh -o StrictHostKeyChecking=no -o UserKnownHostsFile=path/to/apache/writable/dir/.ssh/known_hosts -l deploy -i path/to/key targethost $ sudo -u apache ssh -o StrictHostKeyChecking=no -o UserKnownHostsFile=path/to/apache/writable/dir/.ssh/known_hosts -l deploy -i path/to/key targethost $ sudo -u apache ssh -o StrictHostKeyChecking=no -o UserKnownHostsFile=/dev/null -l deploy -i path/to/key targethost Eventually, I'll be using this solution to run rsync as the apache user.

    Read the article

  • whats the diference between train, validation and test set, in neural networks?

    - by Daniel
    Im using this library http://pastebin.com/raw.php?i=aMtVv4RZ to implement a learning agent. I have generated the train cases, but i dont know for sure what are the validation and test sets, the teacher says: 70% should be train cases, 10% will be test cases and the rest 20% should be validation cases. Thanks. edit i have this code, for training.. but i have no ideia when to stop training.. def train(self, train, validation, N=0.3, M=0.1): # N: learning rate # M: momentum factor accuracy = list() while(True): error = 0.0 for p in train: input, target = p self.update(input) error = error + self.backPropagate(target, N, M) print "validation" total = 0 for p in validation: input, target = p output = self.update(input) total += sum([abs(target - output) for target, output in zip(target, output)]) #calculates sum of absolute diference between target and output accuracy.append(total) print min(accuracy) print sum(accuracy[-5:])/5 #if i % 100 == 0: print 'error %-14f' % error if ? < ?: break

    Read the article

  • what libraries or platforms should I use to build web apps that provide real-time, asynchronous data

    - by Daniel Sterling
    This is a less a question with a simple, practical answer and more a question to foster discussion on the real-time data exchange topic. I'll begin with an example: Google Wave is, at its core, a real-time asynchronous data synchronization engine. Wave supports (or plans to support) concurrent (real-time) document collaboration, disconnected (offline) document editing, conflict resolution, document history and playback with attribution, and server federation. A core part of Wave is the Operational Transformation engine: http://www.waveprotocol.org/whitepapers/operational-transform The OT engine manages document state. Changes between clients are merged and each client has a sane and consistent view of the document at all times; the final document is eventually consistent between all connected clients. My question is: is this system abstract or general enough to be used as a library or generic framework upon which to build web apps that synchronize real-time, asynchronous state in each client? Is the Wave protocol directly used by any current web applications (besides Google's client)? Would it make sense to directly use it for generic state synchronization in a web app? What other existing libraries or frameworks would you consider using when building such a web app? How much code in such an app might be domain-specific logic vs generic state synchronization logic? Or, put another way, how leaky might the state synchronization abstractions be? Comments and discussion welcomed!

    Read the article

  • Misalignement in the output Bitmap created from a byte array

    - by Daniel
    I am trying to understand why I have troubles creating a Bitmap from a byte array. I post this after a careful scrutiny of the existing posts about Bitmap creation from byte arrays, like the followings: Creating a bitmap from a byte[], Working with Image and Bitmap in c#?, C#: Bitmap Creation using bytes array My code is aimed to execute a filter on a digital image 8bppIndexed writing the pixel value on a byte [] buffer to be converted again (after some processing to manage gray levels) in a 8BppIndexed Bitmap My input image is a trivial image created by means of specific perl code: https://www.box.com/shared/zqt46c4pcvmxhc92i7ct Of course, after executing the filter the output image has lost the first and last rows and the first and last columns, due to the way the filter manage borders, so from the original 256 x 256 image i get a 254 x 254 image. Just to stay focused on the issue I have commented the code responsible for executing the filter so that the operation really performed is an obvious: ComputedPixel = InputImage.GetPixel(myColumn, myRow).R; I know, i should use lock and unlock but I prefer one headache one by one. Anyway this code should be a sort of identity transform, and at last i use: private unsafe void FillOutputImage() { OutputImage = new Bitmap (OutputImageCols, OutputImageRows , PixelFormat .Format8bppIndexed); ColorPalette ncp = OutputImage.Palette; for (int i = 0; i < 256; i++) ncp.Entries[i] = Color .FromArgb(255, i, i, i); OutputImage.Palette = ncp; Rectangle area = new Rectangle(0, 0, OutputImageCols, OutputImageRows); var data = OutputImage.LockBits(area, ImageLockMode.WriteOnly, OutputImage.PixelFormat); Marshal .Copy (byteBuffer, 0, data.Scan0, byteBuffer.Length); OutputImage.UnlockBits(data); } The output image I get is the following: https://www.box.com/shared/p6tubyi6dsf7cyregg9e It is quite clear that I am losing a pixel per row, but i cannot understand why: I have carefully controlled all the parameters: OutputImageCols, OutputImageRows and the byte [] byteBuffer length and content even writing known values as way to test. The code is nearly identical to other code posted in stackOverflow and elsewhere. Someone maybe could help to identify where the problem is? Thanks a lot

    Read the article

  • nfs (netapp) question: how to map the device shown in sar -d to the data volume?

    - by Daniel
    Using sar I can see device nfss24 is very busy, but how to know which data volume (file system) the device is for? sar -d 1 10|egrep "busy|nfs" SunOS phxdbnfs11 5.10 Generic_141414-07 sun4v 04/14/2010 19:03:27 device %busy avque r+w/s blks/s avwait avserv 19:03:28 nfs23 0 0.0 0 0 0.0 0.0 nfs24 100 1484053.4 504 32123 2944300.0 47.5 nfs25 0 0.0 0 0 0.0 0.0 nfs26 0 0.0 0 0 0.0 0.0 nfs27 107 1.1 0 0 0.0 0.0 nfs28 107 17.0 0 0 0.0 0.0 nfs29 100 13109.5 460 29435 28451.7 52.0 nfs30 0 0.0 0 0 0.0 0.0 nfs31 107 9.6 0 0 0.0 0.0 nfs32 0 0.0 0 0 0.0 0.0 nfs33 107 1.1 0 0 0.0 0.0 19:03:29 nfs23 0 0.0 0 0 0.0 0.0 nfs24 100 1483762.8 530 33709 2797054.5 45.1 nfs25 0 0.0 0 0 0.0 0.0 nfs26 0 0.0 0 0 0.0 0.0 nfs27 107 1.1 0 0 0.0 0.0 nfs28 107 17.0 0 0 0.0 0.0 nfs29 100 12800.8 511 32732 25016.0 46.8 nfs30 0 0.0 0 0 0.0 0.0 nfs31 107 9.6 0 0 0.0 0.0 nfs32 0 0.0 0 0 0.0 0.0 nfs33 107 1.1 0 0 0.0 0.0 19:03:30 nfs23 0 0.0 0 0 0.0 0.0 nfs24 100 1483080.4 761 48162 1950073.8 31.4 nfs25 0 0.0 0 0 0.0 0.0 nfs26 0 0.0 0 0 0.0 0.0 nfs27 107 1.1 0 0 0.0 0.0 nfs28 107 17.0 0 0 0.0 0.0 nfs29 100 12406.7 737 46855 16800.7 32.4 nfs30 0 0.0 0 0 0.0 0.0 nfs31 107 9.6 0 0 0.0 0.0 nfs32 0 0.0 0 0 0.0 0.0 nfs33 107 1.1 0 0 0.0 0.0

    Read the article

  • Server is on or off

    - by Daniel
    Curious. I'm starting to broadcast high school football games online, and it uses a program to broadcast the feeds off my computer. However, when I shut the program down or the computer down, the server goes offline and guests won't be able to access the feeds. Is there any kind of code out there that I can post onto my website that will indicate to my guests whether the server is on or off? I would figure it would be a simple code, a php script or something that periodically checks to see if a site is on line and then displays ON or OFF.

    Read the article

  • Detecting whether user stayed after prompting onBeforeUnload

    - by Daniel Magliola
    In a web app I'm working on, I'm capturing onBeforeUnload to ask the user whether he really wants to exit. Now, if he decides to stay, there are a number of things I'd like to do. What I'm trying to figure out is that he actually chose to stay. I can of course declare a SetTimeout for "x" seconds, and if that fires, then it would mean the user is still there (because we didn't get unloaded). The problem is that the user can take any time to decide whether to stay or not... I was first hoping that while the dialog was showing, SetTimeout calls would not fire, so I could set a timeout for a short time and it'd only fire if the user chose to stay. However, timeouts do fire while the dialog is shown, so that doesn't work. Another idea I tried is capturing mouseMoves on the window/document. While the dialog is shown, mouseMoves indeed don't fire, except for one weird exception that really applies to my case, so that won't work either. Can anyone think of other way to do this? Thanks! (In case you're curious, the reason capturing mouseMove doesn't work is that I have an IFrame in my page, containing a site from another domain. If at the time of unloading the page, the focus is within the IFrame, while the dialog shows, then I get the MouseMove event firing ONCE when the mouse moves from inside the IFrame to the outside (at least in Firefox). That's probably a bug, but still, it's very likely that'll happen in our case, so I can't use this method).

    Read the article

  • Sql query listing Fathers and childs with joins, how to distinct them?

    - by DaNieL
    Having those tables: table_n1: | t1_id | t1_name | | 1 | foo | table_n2: | t2_id | t1_id | t2_name | | 1 | 1 | bar | I need a query that gives me two result: | names | | foo | | foo / bar | But i cant figure out the right way. I wrote this one: SELECT CONCAT_WS(' / ', table_n1.t1_name, table_n2.t2_name) AS names FROM table_n1 LEFT JOIN table_n2 ON table_n2.t1_id = table_n1.t1_id that works for an half: this only return the 2° row (in the example above): | names | | foo - bar | This query return the 'father' (table_n1) name only when it doesnt have 'childs' (table_n2). How can i fix it?

    Read the article

  • snippet generation in php

    - by daniel
    Hi, I have a long chunk of text that came back from a search query. I'd like to display a snippet of the text, not the entire thing, and highlight the search query within the snippet. I realize that decided what part of the text to slice can be complicated, and I was hoping for any ideas on how do to this? Thanks!

    Read the article

< Previous Page | 35 36 37 38 39 40 41 42 43 44 45 46  | Next Page >