out-of-memory

Java out of memory errors on large WSDLs (play framework)

余生长醉 提交于 2019-12-10 23:55:49
问题 We've got a problem when trying to generate and use a really large proxy file (For the record, it's from a MSCRM Dynamics WSDL). Before I get to the issue: we already have this working in a stand alone app using NetBeans. We generated all the proxy files using "WSDL2Java -uri etc etc". Poked at a few of the web methods and successfully got responses etc. Now, when we try to integrate it into the destination project in eclipse (launched through play framework) it throws out of memory errors.

How to set layout params on an imageView inside GridView in Android

久未见 提交于 2019-12-10 22:38:40
问题 I am new to android and I met this tutorial at the official android site on how to create a GridView of images. I am using kotlin as the language of choice. In the adapter class which extends BaseAdapter , I am trying to set the imageview layoutparams as indicated in the tutorial, but I get an error saying GridView.LayoutParams is unresolved reference. Here is the complete code for the class: class ImageAdapter(val context: Context) : BaseAdapter() { // references to our images val items:

“Out of memory” error for standalone matlab applications - memory fragmentation

时光怂恿深爱的人放手 提交于 2019-12-10 22:02:25
问题 I have to deliver an application as a standalone Matlab executable to a client. The code include a series of calls to a function that internally creates several cell arrays. My problem is that an out-of-memory error happens when the number of calls to this function increases in response to the increase in the user load. I guess this is low-level memory fragmentation as the workspace variables are independent from the number of loops. As mentioned here, quitting and restarting Matlab is the

How to trap the OutOfMemoryException in .NET (Excel add-in)

牧云@^-^@ 提交于 2019-12-10 21:32:14
问题 I am getting OutOfMemory Exception in my .net addin. The addin is using large number of managed and unmanaged objects. Is there a way to trap this exception? Updated: I think any application can get an OutofMemory exception if it processess a large amount of data that needs to be processed and not freed periodically. Suppose I have a method that analyses some structures in memory. I give it 300 structures, it loads each of them in memory, analyses them and completes processing. In this

OutOfMemory error when using Apache Commons lineIterator

非 Y 不嫁゛ 提交于 2019-12-10 20:58:02
问题 I'm trying to iterate line-by-line a 1.2GB file using Apache Commons FileUtils.lineIterator . However, as soon as a LineIterator calls hasNext() I get a java.lang.OutOfMemoryError: Java heap space . I've already allocated 1G to the java heap. What am I doing wrong in here? After reading some docs, isn't LineIterator supposed to be reading the file from the file system and not loading it into memory? Note the code is in Scala: val file = new java.io.File("data_export.dat") val it = org.apache

Android Admob Interstitial Memory leak

南笙酒味 提交于 2019-12-10 20:56:43
问题 I'm trying to show interstitials at the end of some Activities. The problem is the interstitials seem to prevent the Activities from being garbage collected causing an out-of-memory exception. How do i resolve this? Thanks in advance. public class AdActivity extends FragmentActivity{ //... protected InterstitialAd interstitial; @Override protected void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); //... // Create the interstitial. interstitial = new InterstitialAd

Applying non-trivial functions to ordered subsets of data.table

萝らか妹 提交于 2019-12-10 20:49:07
问题 Problem I'm trying to use my newfound data.table powers (for good) to compute the frequency content of a bunch of data that looks like this: | Sample| Channel| Trial| Voltage|Class | Subject| |-------:|--------:|------:|-----------:|:------|--------:| | 1| 1| 1| -196.82253|1 | 1| | 1| 2| 1| 488.15166|1 | 1| | 1| 3| 1| -311.92386|1 | 1| | 1| 4| 1| -297.06078|1 | 1| | 1| 5| 1| -244.95824|1 | 1| | 1| 6| 1| -265.96525|1 | 1| | 1| 7| 1| -258.93263|1 | 1| | 1| 8| 1| -224.07819|1 | 1| | 1| 9| 1| -87

how to face java heap outofmemory error in wave file editor

醉酒当歌 提交于 2019-12-10 18:42:57
问题 I am making a wave file editor using java in which we can cut copy paste the wave file using wave spectrum.For that I am reading the wave file in bytes and converting them to double array.Its working fine for small files.But when I load large wave files at once it is throwing heap outofmemory error as it has to create double array of size framelength of that particular file.Is there any alternative like loading the wave file into parts other than loading complete file at once.I already tried

How to solve the Out of Memory issue while displaying image in android?

我怕爱的太早我们不能终老 提交于 2019-12-10 17:56:17
问题 I am working on a quiz application. In that I am displaying the question and options in a list. I have kept a next button at the top and when the next button is clicked, I am calling the same page again and again until the test is over. Since some questions consist of images I am displaying a button below the question and when the button is clicked, the image will be displayed in the new page. Now my problem is sometimes when I click on the button to display the image it is displaying

Adding large files to IO.Compression.ZipArchiveEntry throws OutOfMemoryException Exception

梦想的初衷 提交于 2019-12-10 17:23:26
问题 I am trying to add a large video file(~500MB) to an ArchiveEntry by using this code: using (var zipFile = ZipFile.Open(outputZipFile, ZipArchiveMode.Update)) { var zipEntry = zipFile.CreateEntry("largeVideoFile.avi"); using (var writer = new BinaryWriter(zipEntry.Open())) { using (FileStream fs = File.Open(@"largeVideoFile.avi", FileMode.Open)) { var buffer = new byte[16 * 1024]; using (var data = new BinaryReader(fs)) { int read; while ((read = data.Read(buffer, 0, buffer.Length)) > 0) {