Search Results

Search found 4695 results on 188 pages for 'jesse bunch'.

Page 20/188 | < Previous Page | 16 17 18 19 20 21 22 23 24 25 26 27  | Next Page >

  • How to convert a C++ program that uses CUDA into MEX

    - by Harold Wellington Graves
    For work, I am converting the Image Denoising program that comes with the CUDA SDK into a MATLAB program. As far as I know, I have made all the necessary changes required by MATLAB, but when I try to call mex on it, MATLAB returns a bunch of linkage errors that I have no idea how to fix. If anyone has any suggestions on what I might be doing wrong, I would greatly appreciate it. The command I am giving MATLAB is: mex imageDenoisingGL.cpp -I..\..\common\inc -IC:\CUDA\include -L..\..\common\lib -lglut32 And the output from MATLAB is a bunch of these: imageDenoisingGL.obj : error LNK2019: unresolved external symbol __imp__cutCheckCmdLineFlag@12 referenced in function "void __cdecl __cutilExit(int,char * *)" (?__cutilExit@@YAXHPAPAD@Z) I am running: Windows XP x32 Visual Studio 2005 MATLAB 2007a

    Read the article

  • Cannot play a recorded sound on device.

    - by B_
    I'm using the exact code from the iPhone Application Programming Guide Multimedia Support to use AVAudioRecorder to record a file to the disk and then AVAudioPlayer to load and play that file. This is working fine in the simulator but is not working on the device. The file gets loaded (we can see the NSTimeInterval) but does not play (play returns false). After it didn't work with the sample code from the website, we tried changing to a bunch of different codecs with no success. And of course, the sound is on. Thanks a bunch.

    Read the article

  • How to inject dependencies into a CustomUserNamePasswordValidator in WCF?

    - by Dannerbo
    I'm using a UserNamePasswordValidator in WCF along with Unity for my dependency injection, but since WCF creates the instance of the UserNamePasswordValidator, I cannot inject my container into the class. So how would one go about this? The simplest solution I can think of is to create a static proxy/wrapper class around a static instance of a UnityContainer, which exposes all the same methods... This way, any class can access the container, and I don't need to inject it everywhere. So I could just do UnityContainerWrapper.Resolve() anywhere in code. So basically this solution solves 2 problems for me, I can use it in classes that I'm not creating an instance of, and I can use it anywhere without having to inject the container into a bunch of classes. The only downside I can think of is that I'm now potentially exposing my container to a bunch of classes that wouldn't of had access to the container before. Not really sure if this is even a problem though?

    Read the article

  • Why is passing a string literal into a char* arguament only sometimes a compiler error?

    - by Brian Postow
    I'm working in a C, and C++ program. We used to be compiling without the make-strings-writable option. But that was getting a bunch of warnings, so I turned it off. Then I got a whole bunch of errors of the form "Cannot convert const char* to char* in argmuent 3 of function foo". So, I went through and made a whole lot of changes to fix those. However, today, the program CRASHED because the literal "" was getting passed into a function that was expecting a char*, and was setting the 0th character to 0. It wasn't doing anything bad, just trying to edit a constant, and crashing. My question is, why wasn't that a compiler error? In case it matters, this was on a mac compiled with gcc-4.0.

    Read the article

  • Count Upwards for ID jQuery

    - by Tom
    Hi Guys, I have the following HTML structure <div id="test-1-yay"></div> ... bunch of code ... <div id="test-2-yay"></div> ... bunch of code ... <div id="test-3-yay"></div> I was wondering how I can use jQuery to basically identify each of these "id's" and then apply some jQuery to them ? I'm new to this so little unsure ? Something like if $('#test-1-yay' || '#test-2-yay' || '#test-3-yay') { do stuff to all ID's } But the prob is I want this to continue as it could go to #test-201-yay, #test-202-yay etc ? Thx

    Read the article

  • Leverage cloud and programming to share GB's of photos

    - by jcmoney
    My friends and I went on a trip and we have over 8 GB of photos we want to share. We live in different geographic locations and all of us (14 people) have a part of the 8 GB. I was wondering if there's a way to leverage my php skills to share all these photos. My current plan is to make a simple site that you can upload a bunch of files and also list those files for people to download (probably a compressed folder of a bunch of selected ones) but was wondering if there's a better way or if I'm grossly underestimating scalability issues. All of us have high speed internet (essentially T1) and I was planning on using Amazon EC2 since this is a heavy task but for a short time period. That's also the reason I can't use dropbox or similar services since they have a 2GB cap (and I don't want to have everyone sign up and install something). I also don't want to set up anything too tricky since not all of them are tech savvy.

    Read the article

  • how to optimize an oracle query that has to_char in where clause for date

    - by panorama12
    I have a table that contains about 49403459 records. I want to query the table on a date range. say 04/10/2010 to 04/10/2010. However, the dates are stored in the table as format 10-APR-10 10.15.06.000000 AM (time stamp). As a result. When I do: SELECT bunch,of,stuff,create_date FROM myTable WHERE TO_CHAR (create_date,'MM/DD/YYYY)' >= '04/10/2010' AND TO_CHAR (create_date, 'MM/DD/YYYY' <= '04/10/2010' I get 529 rows but in 255.59 seconds! which is because I guess I am doing to_char on EACH record. However, When I do SELECT bunch,of,stuff,create_date FROM myTable WHERE create_date >= to_date('04/10/2010','MM/DD/YYYY') AND create_date <= to_date('04/10/2010','MM/DD/YYYY') then I get 0 results in 0.14 seconds. How can I make this query fast and still get valid (529) results?? At this point I can not change indexes. Right now I think index is created on create_date column

    Read the article

  • How do I manage permissions on multiple items in SharePoint 2007?

    - by mk
    I'm relatively new to SharePoint and am trying to put a bunch of Word files (that were on our network file server) into SharePoint. We have set up a document library that, by default, gives everyone access to everything. This is the desired top-level permission set because most items will work well this way. The problem is that I have a bunch of documents I want to add and apply some specific permissions to. I can do this, but...please tell me there is some way I can do this for multiple documents at the same time. Attempting to do this one-by-one is a pain and I'm hoping for a better solution here. Thanks very much in advance.

    Read the article

  • Customized generation/filtering resources with maven

    - by zamza
    I wonder what is the Maven way in my situation. My application has a bunch of configuration files, let's call them profiles. Each profile configuration file is a *.properties file, that contains keys/values and some comments on these keys/values semantics. The idea is to generate these *.properties to have unified comments in all of them. My plan is to create a template.properties file that contains something like #Comments for key1/value1 key1=${key1.value} #Comments for key2/value2 key2=${key2.value} and a bunch of files like #profile_data_1.properties key1.value=profile_1_key_1_value key2.value=profile_1_key_2_value #profile_data_2.properties key1.value=profile_2_key_1_value key2.value=profile_2_key_2_value Then bind to generate-resources phase to create a copy of template.properties per profile_data_*, and filter that copy with profile_data_*.properties as a filter. The easiest way is probably to create an ant build file and use antrun plugin. But that is not a Maven way, is it? Other option is to create a Maven plugin for that tiny task. Somehow, I don't like that idea (plugin deployment is not what I want very much).

    Read the article

  • Rebasing a core repo in git.

    - by b. e. hollenbeck
    I have a customized fork of CodeIgniter that I use as a standard baseline for several projects. Recently, I've made significant improvements in this repo that I want to use to update the client projects that use it. What I can't seem to figure out is how to pull in the changes to a client project. So I have: Baseline: A--B--C--D--E Client cloned @ C C'--D'--E' And I want to update the client repo to E from the Baseline project. I've tried rebase, and it has erased the files not present in the baseline project (views and such), and creates a bunch of conflicts that really don't need to be conflicts with things like the default HTML5 boilerplate that I use. Is there an option for rebase that I should be using? Is there a different way to approach it? Do I need a bunch of .gitignores for the content directories?

    Read the article

  • Isolating read and write in multithreaded

    - by the_lotus
    Hi In a multithreaded application. I have a bunch of function that loop through a collection to read the information. I also have a bunch of function that modifies that same collection. I’m looking for a way to isolate all the read and the write together. I don’t want a write to be done while a read is in progress. I was thinking of using SyncLock on the collection object but this will block multiple read trying to work in parallel.

    Read the article

  • Is there a name for a pure-data Objective-C class?

    - by BrianEnigma
    This is less of a code-specific question and more of an Objective-C nomenclature question. In C you have struct for pure data. In Enterprise Java, you have "bean" classes that are purely member variables with getters and setters, but no business logic. In Adobe FLEX, you have "Value Objects". In Objective-C, is there a proper name for an object (descended from NSObject, of course) that simply has ivars and getters/setters (or @property/@synthesize, if you want to get fancy) and no real business logic? A more concrete example might be a simple class with getters and setters for filename, file size, description, and assorted other metadata. You could then take a bunch of these and easily throw them into a container (NSDictionary, NSArray) without the need for messy NSValue wrapping of a C struct. It is also a little more structure than putting, say, a bunch of loosely-typed child NSDictionaries into a parent container object.

    Read the article

  • Is it bad practice to declare an array mid-function...

    - by Maximus
    In C, which would be more proper... void MyFunction() { int* array; int size; //do a bunch of stuff size = 10; array = (int*)(sizeof(int)*size); //do more stuff... //no longer need array... free(array); } Or is something like this okay? void MyFunction() { int size; //do a bunch of stuff size = 10; array[size]; //do more stuff... } The malloc uses the heap instead of the stack, so I suppose if you know size is going to be very large you'd want to malloc... but if you're quite certain size will be small enough, would the second method be reasonable?

    Read the article

  • Subfloat figures in latex

    - by jp88
    I am inputting a bunch of figures in Latex using \begin{figure}[h] \centering \subfloat etc. How do I get the subfloat figures to go to the next page? What I mean is, I'm inputting a ton of figures so it'll definitely be more than one page but if I do separate figures for each the a, b, c, d, etc. for the captions will change, so ideally I'd like one enormous figure with a bunch of subfloats a through z on different pages - how do you do that? Right now, I simply can't see the subfloat figures that stretch over the page, so I'll need to get another page somehow.

    Read the article

  • requireJS : How to structure Javascript for an entire site?

    - by pagewil
    I have 3000+ lines of javascript that I need to get into a sensible/maintainable structure. I have chosen to use requireJS as it has been recommend to me by a few people. I have a bunch of variables that are used throughout the application and need to be available everywhere. I also have a bunch of functions that need to be available everywhere. Apart from these two dependencies most of the code can be divided off into their own modules. I am having trouble understanding how to manage my main variables so that if one module of code makes changes to the variables the rest of the JS modules will see that change. I think I need to see a few examples that demonstrate how requireJS is intended to work on a larger scale that the examples in the documentation. If anyone is an experienced requireJS user I would love the hear your tips!

    Read the article

  • what's the right way to do polymorphism with protocol buffers?

    - by user364003
    I'm trying to long-term serialize a bunch of objects related by a strong class hierarchy in java, and I'd like to use protocol buffers to do it due to their simplicity, performance, and ease of upgrade. However, they don't provide much support for polymorphism. Right now, the way I'm handling it is by having a "one message to rule them all" solution that has a required string uri field that allows me to instantiate the correct type via reflection, then a bunch of optional fields for all the other possible classes I could serialize, only one of which will be used (based on the value of the uri field). Is there a better way to handle polymorphism, or is this as good as I'm going to get?

    Read the article

  • JMS On demand Support Active MQ with Spring

    - by user345275
    Hi Team I am involving in SMS Gate way project. The Very Base function is our system have couple of Customers They will send their request to our gateway in a form of XML. Those request is Process first and send it to a common out bound JMS(ActiveMQ 5.3 ) There is an listener running on which should be capable of doing the following 1. Retrive Bunch of Messages(Let say 5 ) on retrieval. 2. The retival should be on demand .It means ,once the listeners triggers only those bunch of message should return . Guys i really need ur help.If you have any idea please help me ou

    Read the article

  • Java: Is it possible to take a GUI Panel and output it into a picture?

    - by user369748
    So I have this chart that's a little special. Kind of like an XY plot of points but my boss wanted to look like a bunch of boxes rather than dots connected by lines. And I basically made a chart using gridlayout and a whole bunch of cells that I'll be colouring in black or white depending on the data. Now he sorta wants it to be outputted to a image file. Is there any way to save a Panel into a picture? He wants to display not only the data but also save a visual representation of the data into an image file.

    Read the article

  • TSQL - create a stored proc inside a transaction statement

    - by Chris L
    I have a sql script that is set to roll to production. I've wrapped the various projects into separate transactions. In each of the transactions we created stored procedures. I'm getting error messages Msg 156, Level 15, State 1, Line 4 Incorrect syntax near the keyword 'procedure'. I created this example script to illustrate Begin Try Begin Transaction -- do a bunch of add/alter tables here -- do a bunch of data manipulation/population here -- create a stored proc create procedure dbo.test as begin select * from some_table end Commit End Try Begin Catch Rollback Declare @Msg nvarchar(max) Select @Msg=Error_Message(); RaisError('Error Occured: %s', 20, 101,@Msg) With Log; End Catch The error seems to imply that I can't create stored procs inside of transaction, but I'm not finding any docs that say otherwise(maybe google isn't being freindly today).

    Read the article

  • Qt: How to force a hidden widget to calculate its layout?

    - by Chris
    What I am trying to do is render a qwidget onto a different window (manually using a QPainter) I have a QWidget (w) with a layout and a bunch of child controls. w is hidden. Until w is shown, there is no layout calculations happening, which is expected. When I call w->render(painter, w->mapToGlobal(QPoint(0,0)), I get a bunch of controls all overlapping each other. w->layout()->activate();w->layout()->update() doesn't seem to do anything. Is there a way to force the layout to happen without showing w?

    Read the article

  • Sorting results by a char(1) column

    - by Brandon
    I have a stored procedure which basically does something like select top 1 expiryDate, flag, (bunch of other columns) from someTable (bunch of joins) order by expiryDate desc So this will grab the record that expires last. This works for most cases, except some records have a flag that are just a char(1). Most of the time it's just Y or N. So it'll return something like 2010-12-31 N 2010-10-05 Y 2010-08-05 N 2010-03-01 F 2010-01-31 N This works, most of the time, but is there any way to order it by the Flag column as well? So I'd want to group the results by Y, then N, and F and any other flags can go last in any order. I thought this would just be an order by, but since the flags are not weighted by the alphabetic value, I'm a little stumped. (Note: These are not my tables, I don't know if using the characters like this was a good idea or not, but it's not something I can change).

    Read the article

  • Display popup window for a CD.

    - by SLC
    Got a CD with a bunch of tutorials etc. done in HTML. What I want is to have a browser window open with no toolbars, fixed width/height etc. because the content is designed to fit nicely into such a window. You can do this with window.open and put a bunch of parameters in, but this triggers popup blockers and activex warnings. Also it looks kinda bad, as the original window doesn't close without a hack that also generates problems. Is there a nice way I can achieve this effect? I could perhaps compile an .exe to autorun on the CD to launch this, but I wouldn't know how to get an .exe to open a window with toolbars etc. turned off.

    Read the article

  • Using varible in re.match in python

    - by screwuphead
    I am trying to create an array of things to match in a description line. So I cant ignore them later on in my script. Below is a sample script that I have been working on, on the side. Basically I am trying to take a bunch of strings and match it against a bunch of other strings. AKA: asdf or asfs or wrtw in string = true continue with script if not print this. import re ignorelist = ['^test', '(.*)set'] def guess(a): for ignore in ignorelist: if re.match(ignore, a): return('LOSE!') else: return('WIN!') a = raw_input('Take a guess: ') print guess(a) Thanks

    Read the article

  • Many Buttons on a Page, Need to send back Unique Post Data with each

    - by CoffeeAddict
    I'm listing out a bunch of cars with a button next to them that when clicked will need to perform a GET but also sends over that item's model.Name: @using (Html.BeginForm("GetCarUrl", "Car", FormMethod.Get, new { model = Model })) { if(Model.Cars != null && Model.Cars.Count > 0) { foreach (CarContent car in Model.Cars) { <p>@car.Name</p> } <input type="button" value="Get Car Url" class="submit" /> } So the page renders a bunch of hyperlinks and buttons: [hyperlink1] [submit] [hyperlink2] [submit] [hyperlink3] [submit] [hyperlink4] [submit] [hyperlink5] [submit] ... When a user clicks on any of the submits, I need to pass back its corresponding @car.CarType for that specific hyperlink Not sure how to go about this. My action method expects a @car.CarType for that specific car hyperlink to be sent to it

    Read the article

  • Apache 2.2 and FastCGI stops responding, warnings, crashes

    - by Brett
    I've seen this question posted a few times using a Google search, with no real answers. I have a multi-threaded FastCGI application running with Apache 2.2 on FreeBSD 7.2. There are a few issues with it, and I am unable to really figure out the source of the problem even after poking through a bunch of the mod_fastcgi source code. My FastCGI application gets anywhere from 2 to 15 or so hits per second, and mostly services a back-end API (the majority of web server usage is for this, and not actually serving content). Everything seems to work ok under normal conditions, but recently this problem has been becoming worse. It starts out with the FastCGI process manager apparently trying to close unneeded processes, sending them a SIGTERM signal. I catch the signal, clean up some stuff, and exit (by calling exit()) with status code 0. This process seems to result in three log messages in my httpd error log: [Tue Jun 01 14:03:31 2010] [warn] FastCGI: (dynamic) server "/home/program/wwwroot/domains/www.mydomain.com/cgi-bin/program.cgi" (pid 98182) termination signaled [Tue Jun 01 14:03:31 2010] [warn] FastCGI: (dynamic) server "/home/program/wwwroot/domains/www.mydomain.com/cgi-bin/program.cgi" (pid 98182) terminated by calling exit with status '0' [Tue Jun 01 14:03:31 2010] [warn] FastCGI: (dynamic) server "/home/program/wwwroot/domains/www.mydomain.com/cgi-bin/program.cgi" restarted (pid 98294) I am not sure why it says it is restarting the process, but in any case no core dump is ever generated so I do believe it is the FastCGI process manager doing it's thing. This makes sense because it begins to happen after the initial load increase from restarting Apache. Since it's down for a few seconds, it gets hit with a couple of hundred requests over the first few seconds it's running again (sometimes even hitting the upper limit of MAXCLIENTS in Apache), and this seems to be the process manager doing the work of spawning more processes to handle the increased load. So this all seems fine, but here is where things get weird. There are really two problems that I see. First, my multithreaded FastCGI process spawns 25 worker threads, and all seem to be used according to my internal log files (multiple processes are clearly using multiple threads to do work). However it seems that 3 or 4 FastCGI processes is not enough to handle the 5 to 15 hit per second load, even though the requests take about .02s or so to process internally. In order to be at all responsive, it seems I need 50 or more FastCGI processes, leading me to believe that FastCGI does not realize that my program is multithreaded. I've read the documentation at http://www.fastcgi.com/mod_fastcgi/docs/mod_fastcgi.html and do not see any option pertaining to multithreaded-ness, and my internal code is more or less set up just like the examples provided by the FastCGI library. The second problem I am having is that once process termination has happened a bunch of times as above (and seemingly at random), I begin getting a lot of these messages in my error log: [Tue Jun 01 14:06:22 2010] [warn] (32)Broken pipe: FastCGI: write() to PM failed (ignore if a restart or shutdown is pending) The messages occur for about half the hits I get to the server, and it completely kills the responsiveness of my application - it seems FastCGI will look for a working "pipe" until it finds one, and fail to realize that whatever application it is trying to contact is dead. It does still work though, it's just incredibly unresponsive - sometimes taking up to 40 or so seconds to process a request. I recompiled mod_fastcgi with some extra debugging around the point of the error message, and it appears that the error happens when it tries to write() to the application. The call to write() fails with a -1 return code, and sets errno to EPIPE. I am noticing that the issue happens mostly when either a crash occurs in one of the FastCGI processes, or a bunch of them are seemingly terminated by the process manager. I haven't had any core dumps though, except for one, where the backtrace outputted by gdb is just a single call to free() at address 0x0000000000000000 with nothing else in the stack trace, so I don't really know what to make of that. I'm thinking it happens sometime after the SIGTERM signal is caught, maybe some global variable not being cleaned up properly or something.

    Read the article

< Previous Page | 16 17 18 19 20 21 22 23 24 25 26 27  | Next Page >