Bay 12 Games Forum

Please login or register.

Login with username, password and session length
Advanced search  
Pages: 1 ... 610 611 [612] 613 614 ... 796

Author Topic: if self.isCoder(): post() #Programming Thread  (Read 886462 times)

3man75

  • Bay Watcher
  • I will fire this rocket
    • View Profile
Re: if self.isCoder(): post() #Programming Thread
« Reply #9165 on: February 28, 2016, 06:48:44 pm »


 e.g. when I'm searching an array (where the indexes are from zero to n-1), I usually set the initial "found" index to -1, and if it's still -1 after the for loop, I didn't find what i am looking for.

I don't think I follow. What is n-1?

I know arrays start at 0 and then go from their up to whatever the max or size is. int array x [4]; would mean it starts at 0 and ends at 3.

The part i'm really confused with your comment is initializing it to -1 and going from their...can you please elaborate a bit?
Logged

Putnam

  • Bay Watcher
  • DAT WIZARD
    • View Profile
Re: if self.isCoder(): post() #Programming Thread
« Reply #9166 on: February 28, 2016, 06:51:42 pm »

n is size

3man75

  • Bay Watcher
  • I will fire this rocket
    • View Profile
Re: if self.isCoder(): post() #Programming Thread
« Reply #9167 on: February 28, 2016, 06:56:29 pm »

So n-1 just accounts for the fact that computers start from zero?
Logged

Reelya

  • Bay Watcher
    • View Profile
Re: if self.isCoder(): post() #Programming Thread
« Reply #9168 on: February 28, 2016, 07:01:29 pm »

"0 to n-1" is how people normally explain array indexes. I use a negative number as a "default" value because it never appears as a valid index. e.g. consider the problem with this search algorithm:

Spoiler (click to show/hide)

^ If I do this then I have a big problem if the "found" value was at index zero: the code never notices it was found. But if I use -1 as a "default", then I don't have that problem anymore:
Spoiler (click to show/hide)
« Last Edit: February 28, 2016, 07:06:12 pm by Reelya »
Logged

TheBiggerFish

  • Bay Watcher
  • Somewhere around here.
    • View Profile
Re: if self.isCoder(): post() #Programming Thread
« Reply #9169 on: February 28, 2016, 08:04:49 pm »

No, he meant null has a value of zero in most c-based languages, not "letter o".
No, I meant 'set your object equal to null'.  And then if(o==null){/*reinitializer*/}
Logged
Sigtext

It has been determined that Trump is an average unladen swallow travelling northbound at his maximum sustainable speed of -3 Obama-cubits per second in the middle of a class 3 hurricane.

EnigmaticHat

  • Bay Watcher
  • I vibrate, I die, I vibrate again
    • View Profile
Re: if self.isCoder(): post() #Programming Thread
« Reply #9170 on: March 01, 2016, 11:18:56 pm »

I just had the most confusing thing happen to me.  Put a .dll in System32, then went to add it as a reference in VS 2015.  Now, this not working wouldn't have been a surprise.  What is a surprise is that its just... not showing up in the browser?  All the other .dlls are.  The file shows up in windows explorer but when I hit "browse" on the add reference window in VS its just not there.  Even if I set the browser to "all files".  This has never happened to me before, on any program.
Logged
"T-take this non-euclidean geometry, h-humanity-baka. I m-made it, but not because I l-li-l-like you or anything! I just felt s-sorry for you, b-baka."
You misspelled seance.  Are possessing Draignean?  Are you actually a ghost in the shell? You have to tell us if you are, that's the rule

Malus

  • Bay Watcher
    • View Profile
Re: if self.isCoder(): post() #Programming Thread
« Reply #9171 on: March 02, 2016, 07:18:06 am »

I just had the most confusing thing happen to me.  Put a .dll in System32, then went to add it as a reference in VS 2015.  Now, this not working wouldn't have been a surprise.  What is a surprise is that its just... not showing up in the browser?  All the other .dlls are.  The file shows up in windows explorer but when I hit "browse" on the add reference window in VS its just not there.  Even if I set the browser to "all files".  This has never happened to me before, on any program.
Not 100% sure how linking works with the VS IDE (I usually build from the command line and link with /link) but is it normal to just dump .dlls into System32? Wouldn't it be better to add them to your project directory? I guess I only ever statically link so I've never run into this issue...
Logged

EnigmaticHat

  • Bay Watcher
  • I vibrate, I die, I vibrate again
    • View Profile
Re: if self.isCoder(): post() #Programming Thread
« Reply #9172 on: March 02, 2016, 03:21:03 pm »

I dunno, I don't mess around with .dlls very often.  Dumped it in the default directory VS looks for .dlls and it works now.  Still weird that it didn't show up in the list at all seeing as how it is a file and all that.
Logged
"T-take this non-euclidean geometry, h-humanity-baka. I m-made it, but not because I l-li-l-like you or anything! I just felt s-sorry for you, b-baka."
You misspelled seance.  Are possessing Draignean?  Are you actually a ghost in the shell? You have to tell us if you are, that's the rule

da_nang

  • Bay Watcher
  • Argonian Overlord
    • View Profile
Re: if self.isCoder(): post() #Programming Thread
« Reply #9173 on: March 02, 2016, 06:07:32 pm »

Alright, this OpenCL kernel is starting to bug me to death. AKA I can't find the damn bug.

Running it on an AMD Radeon HD 6850, OpenCL version 1.1. The kernel takes in data from two equal-length lists of galaxies and calculates a histogram based on the angular separation. I run three iterations of this kernel, each one with different lists. AFAIK, they all run fine give or take some floating point differences. The exception is the first iteration, where the first element in the histogram is always, no matter what, the length of the list, even though each work-item prints out correct values from atomic_inc. Really, WTF.

Code: (Kernel (Unoptimized, I know)) [Select]
__kernel void histogram(
__global float *ascension,
__global float *declination,
__global float *ascension2,
__global float *declination2,
__global int *separation,
__local int *bins,
const int doubleList)
{

/* SETUP */
size_t xIndex = get_global_id(0);
size_t yIndex = get_global_id(1);

/* Calculate angles of separation in degrees */

if ((xIndex < yIndex) || (doubleList == 1)) {


float a1 = ascension[xIndex]/10800;
float d1 = declination[xIndex]/10800;
float a2 = ascension2[yIndex]/10800;
float d2 = declination2[yIndex]/10800;

float da = a2 - a1;
float A = cospi(d2)*sinpi(da);
float B = cospi(d1)*sinpi(d2) - sinpi(d1)*cospi(d2)*cospi(da);
float C = sinpi(d1)*sinpi(d2) + cospi(d1)*cospi(d2)*cospi(da);
float theta = 180*atan2pi(sqrt(pow(A,2) + pow(B,2)), C);

if (theta >= 0 && theta <= 64) {

int binId = convert_int_rtn(4*theta);
int old = atomic_inc(&separation[binId]);
if (binId == 0) printf("OCL: (%d,%d): %8f\t%d\r\n", xIndex, yIndex, theta, old);
}

}

}


Code: (Rest of the program) [Select]
#include <fstream>
#include <sstream>
#include <iostream>
#include <cstdlib>
#include <cmath>
#include <time.h>
#include <CL/cl.h>
#define ERR(msg) printf("\nError: %s : %d\n", (msg), __LINE__)


int loadKernelSource(const char* filename, std::string &outputSource) {
std::ifstream filestream(filename);
std::stringstream stream;
stream << filestream.rdbuf();
outputSource = stream.str();
const size_t length = outputSource.length();


stream.flush();
filestream.close();
return length;
}

int outputData(const char* filename, int *DD, int *DR, int *RR, float *omega) {
std::ofstream filestream(filename);
for(int k=0; k < 256; k++) {
filestream << DD[k] << "," << DR[k] << "," << RR[k] << "," << omega[k] << std::endl;
}
filestream.close();
return 0;
}

void loadData(const char* filename, float** ascension, float** declination, int &numData) {
std::ifstream filestream(filename);
filestream >> numData;
#ifdef DATA_SIZE
numData = (DATA_SIZE >= numData)? numData : DATA_SIZE;
#endif

*ascension = new float[numData];
*declination = new float[numData];

for(int k = 0; k<numData; k++) {
filestream >> *(*ascension + k);
filestream >> *(*declination + k);
}

filestream.close();
}

void testRun(float* ascension, float* declination, float* ascension2, float* declination2,
int* separation, int sizex, int sizey, int doubleList) {
for(int i = 0; i < sizex; i++) {
//for(int j = (1-doubleList)*(i+1);j < sizey; j++) {
for(int j = 0;j < sizey; j++) {
if((i < j) || (doubleList == 1)){
#define PI 3.1415927 //Accurate witin floating point precision

float a1 = ascension[i]/10800;
float d1 = declination[i]/10800;
float a2 = ascension2[j]/10800;
float d2 = declination2[j]/10800;

float da = a2 - a1;

float A = cos(PI*d2)*sin(PI*da);
float B = cos(PI*d1)*sin(PI*d2) - sin(PI*d1)*cos(PI*d2)*cos(PI*da);
float C = sin(PI*d1)*sin(PI*d2) + cos(PI*d1)*cos(PI*d2)*cos(PI*da);

float theta = 180*atan2(sqrt(pow(A,2) + pow(B,2)), C)/PI;

if (theta >= 0 && theta <= 64) {
int binId = (int) floor(4*theta);
separation[binId]++;
}}
}
}

}

cl_int runKernel(cl_command_queue *queue, cl_kernel *kernel,
cl_mem *a1, cl_mem *d1, cl_mem *a2, cl_mem *d2, cl_mem *s,
int *doubleList, size_t* size, cl_event *event) {

cl_int err = clSetKernelArg(*kernel, 0, sizeof(cl_mem), a1);
err |= clSetKernelArg(*kernel, 1, sizeof(cl_mem), d1);
err |= clSetKernelArg(*kernel, 2, sizeof(cl_mem), a2);
err |= clSetKernelArg(*kernel, 3, sizeof(cl_mem), d2);
err |= clSetKernelArg(*kernel, 4, sizeof(cl_mem), s);
err |= clSetKernelArg(*kernel, 5, 256*sizeof(int), NULL);
err |= clSetKernelArg(*kernel, 6, sizeof(int), doubleList);

if (err != CL_SUCCESS) {ERR("Set Arguments"); return err;};

err = clEnqueueNDRangeKernel(*queue, *kernel, 2, NULL, size, NULL, 0, NULL, event);

if (err != CL_SUCCESS) {ERR("Execution"); return err;}

return err;

}

int main(int argc, char** argv) {

/* Load kernel source */
std::string source;
loadKernelSource("histogram.cl", source);

int numData;
int numRand;
int bufferSize;

float *dataAsc;
float *dataDec;
float *randAsc;
float *randDec;
int DD[256];
int DR[256];
int RR[256];
int testDD[256];
int testDR[256];
int testRR[256];
float omega[256];

#ifdef PROFILE
clock_t start, end;
clock();
#ifdef PROFILE_CPU
clock_t t[4];
#endif
#endif

/* Load data */
loadData("data_100k_arcmin.txt", &dataAsc, &dataDec, numData);
loadData("flat_100k_arcmin.txt", &randAsc, &randDec, numRand);

bufferSize = (numData >= numRand)? numData : numRand;

std::cout << "Number of data points: " << numData << std::endl;
for(int k=0; k < 10; k++) { std::cout << std::endl << dataAsc[k] << "\t\t" << dataDec[k];}
std::cout << "\n..." << std::endl;
std::cout << dataAsc[numData-1] << "\t\t" << dataDec[numData-1];
std::cout << "\n\n";

std::cout << "Number of data points: " << numRand << std::endl;
for(int k=0; k < 10; k++) { std::cout << std::endl << randAsc[k] << "\t\t" << randDec[k];}
std::cout << "\n..." << std::endl;
std::cout << randAsc[numRand-1] << "\t\t" << randDec[numRand-1];
std::cout << "\n\n";

/* Find platform */

cl_platform_id platform;

cl_int err;

err = clGetPlatformIDs(1,&platform, NULL);

if (err != CL_SUCCESS) {ERR("Platform"); exit(1);}

/* Find device */

cl_device_id device;

err = clGetDeviceIDs(platform,CL_DEVICE_TYPE_GPU, 1, &device, NULL);

if (err != CL_SUCCESS) {ERR("Device"); exit(1);}

/* Create context */

cl_context context = clCreateContext(NULL, 1, &device, NULL, NULL, &err);

if (!context) {ERR("Context"); exit(1);}

/* Create command queue */

cl_command_queue queue = clCreateCommandQueue(context, device, 0, &err);

if (!queue) {ERR("Command Queue"); exit(1);}

/* Create program */

const char* programSource = source.c_str();

cl_program program = clCreateProgramWithSource(context, 1, &programSource, NULL, &err);

if (!program) {ERR("Program"); exit(1);}

/* Build program */

err = clBuildProgram(program, 1, &device, NULL, NULL, NULL);

if (err != CL_SUCCESS) {
ERR("Build");
char output[200000];
clGetProgramBuildInfo(program, device, CL_PROGRAM_BUILD_LOG, 200000*sizeof(char), &output, NULL);
std::cout << "Compiler output:\n\n" << output << std::endl;
exit(1);
}

/* Create kernel */

cl_kernel kernel = clCreateKernel(program, "histogram", &err);

if (!kernel || err != CL_SUCCESS) {ERR("Kernel"); exit(1);}

/* Create buffers */

cl_mem ascension = clCreateBuffer(context, CL_MEM_READ_ONLY, bufferSize*sizeof(float), NULL, &err);

if (!ascension || err != CL_SUCCESS) {ERR("Buffer Ascension"); exit(1);}

cl_mem ascension2 = clCreateBuffer(context, CL_MEM_READ_ONLY, bufferSize*sizeof(float), NULL, &err);

if (!ascension || err != CL_SUCCESS) {ERR("Buffer Ascension"); exit(1);}

cl_mem declination = clCreateBuffer(context, CL_MEM_READ_ONLY, bufferSize*sizeof(float), NULL, &err);

if (!declination || err != CL_SUCCESS) {ERR("Buffer Declination"); exit(1);}

cl_mem declination2 = clCreateBuffer(context, CL_MEM_READ_ONLY, bufferSize*sizeof(float), NULL, &err);

if (!declination || err != CL_SUCCESS) {ERR("Buffer Declination"); exit(1);}

cl_mem separation = clCreateBuffer(context, CL_MEM_READ_WRITE, 256*sizeof(int), NULL, &err);

if (!separation || err != CL_SUCCESS) {ERR("Buffer Separation"); exit(1);}

cl_mem separation2 = clCreateBuffer(context, CL_MEM_READ_WRITE, 256*sizeof(int), NULL, &err);

if (!separation || err != CL_SUCCESS) {ERR("Buffer Separation"); exit(1);}

cl_mem separation3 = clCreateBuffer(context, CL_MEM_READ_WRITE, 256*sizeof(int), NULL, &err);

if (!separation || err != CL_SUCCESS) {ERR("Buffer Separation"); exit(1);}

/* Start running kernels */

#ifdef PROFILE
start = clock();
#endif

int doubleList = 0;

size_t size[2] = {numData, numData};

err = clEnqueueWriteBuffer(queue, ascension, CL_TRUE, 0,
numData*sizeof(float), dataAsc, 0, NULL, NULL);
err |= clEnqueueWriteBuffer(queue, declination, CL_TRUE, 0,
numData*sizeof(float), dataDec, 0, NULL, NULL);
err |= clEnqueueWriteBuffer(queue, ascension2, CL_TRUE, 0,
numData*sizeof(float), dataAsc, 0, NULL, NULL);
err |= clEnqueueWriteBuffer(queue, declination2, CL_TRUE, 0,
numData*sizeof(float), dataDec, 0, NULL, NULL);
err |= clEnqueueWriteBuffer(queue, separation, CL_TRUE, 0,
256*sizeof(int), DD, 0, NULL, NULL);

if (err != CL_SUCCESS) {ERR("Buffer Write"); exit(1);}

err = runKernel(&queue, &kernel,
&ascension, &declination, &ascension2, &declination2, &separation, &doubleList, size, NULL);

if (err != CL_SUCCESS) {ERR("Execution"); exit(1);}

err = clEnqueueReadBuffer(queue, separation, CL_TRUE, 0, 256*sizeof(int), DD, 0, NULL, NULL);

if (err != CL_SUCCESS) {ERR("Read Buffer"); exit(1);}

err = clEnqueueWriteBuffer(queue, ascension2, CL_TRUE, 0,
numRand*sizeof(float), randAsc, 0, NULL, NULL);
err |= clEnqueueWriteBuffer(queue, declination2, CL_TRUE, 0,
numRand*sizeof(float), randDec, 0, NULL, NULL);
err |= clEnqueueWriteBuffer(queue, separation2, CL_TRUE, 0,
256*sizeof(int), DR, 0, NULL, NULL);

if (err != CL_SUCCESS) {ERR("Buffer Write"); exit(1);}

size[2] = numRand;
doubleList = 1;

err = runKernel(&queue, &kernel,
&ascension, &declination, &ascension2, &declination2, &separation2, &doubleList, size, NULL);

if (err != CL_SUCCESS) {ERR("Execution"); exit(1);}

err = clEnqueueReadBuffer(queue, separation2, CL_TRUE, 0, 256*sizeof(int), DR, 0, NULL, NULL);

if (err != CL_SUCCESS) {ERR("Read Buffer"); exit(1);}

err = clEnqueueWriteBuffer(queue, ascension, CL_TRUE, 0,
numRand*sizeof(float), randAsc, 0, NULL, NULL);
err |= clEnqueueWriteBuffer(queue, declination, CL_TRUE, 0,
numRand*sizeof(float), randDec, 0, NULL, NULL);
err |= clEnqueueWriteBuffer(queue, separation3, CL_TRUE, 0,
256*sizeof(int), RR, 0, NULL, NULL);

if (err != CL_SUCCESS) {ERR("Buffer Write"); exit(1);}

size[1] = numRand;
doubleList = 0;

err = runKernel(&queue, &kernel,
&ascension, &declination, &ascension2, &declination2, &separation3, &doubleList, size, NULL);

if (err != CL_SUCCESS) {ERR("Execution"); exit(1);}

err = clEnqueueReadBuffer(queue, separation3, CL_TRUE, 0, 256*sizeof(int), RR, 0, NULL, NULL);

if (err != CL_SUCCESS) {ERR("Read Buffer"); exit(1);}

clFinish(queue);

#ifdef PROFILE
end = clock();
#endif

printf("%d\n", DD[0]);

/* Output results to console */

std::cout << "\nValues:\n\n";

/* Optional CPU test run */

#ifdef TEST
#ifdef PROFILE_CPU
t[0] = clock();
testRun(dataAsc, dataDec, dataAsc, dataDec, testDD, numData, numData, 0);
t[1] = clock();
testRun(dataAsc, dataDec, randAsc, randDec, testDR, numData, numRand, 1);
t[2] = clock();
testRun(randAsc, randDec, randAsc, randDec, testRR, numRand, numRand, 0);
t[3] = clock();
#else
testRun(dataAsc, dataDec, dataAsc, dataDec, testDD, numData, numData, 0);
testRun(dataAsc, dataDec, randAsc, randDec, testDR, numData, numRand, 1);
testRun(randAsc, randDec, randAsc, randDec, testRR, numRand, numRand, 0);
#endif

unsigned long sumDD = 0;
unsigned long sumDR = 0;
unsigned long sumRR = 0;
bool equal = true;
bool testEqual;
for(int k=0; k < 256; k++) {
testEqual = (testDD[k] == DD[k]) && (testDR[k] == DR[k]) && (testRR[k] == RR[k]);
std::cout << DD[k] << "\t" << testDD[k]
<< "\t" << DR[k] << "\t" << testDR[k]
<< "\t" << RR[k] << "\t" << testRR[k] << "\t" << testEqual << std::endl;
sumDD += testDD[k];
sumDR += testDR[k];
sumRR += testRR[k];
equal = equal && testEqual;
}
std::cout << "Total pairs in range 0-64 degrees: " <<
sumDD << "\t" << sumDR << "\t" << sumRR << std::endl;
std::cout << "Are they equal (beware floating point differences): " << equal << std::endl;

#else
printf("%8s\t%8s\t%8s\t%8s\n", "DD", "DR", "RR", "Omega");
for(int k=0; k < 256; k++) {
omega[k] = (DD[k] - 2*DR[k] + RR[k])/((float) RR[k]);
printf("%8d\t%8d\t%8d\t%8f\n", DD[k], DR[k], RR[k], omega[k]);
}
#endif

/* Optional profile results */

#ifdef PROFILE
#ifdef TEST
#ifdef PROFILE_CPU
std::cout << "\n Individual timings:" << std::endl;
printf("%8s\n", "Sequntial CPU");
for(int k=0; k < 3; k++) {
printf("%8f\n", (t[k+1] - t[k])/((double) CLOCKS_PER_SEC));
}
#endif
#endif

std::cout << "\n Total execution time of histograms:" << std::endl;
printf("%8f", (end - start)/((double) CLOCKS_PER_SEC));
#ifdef TEST
#ifdef PROFILE_CPU
printf("\t%8f", (t[3] - t[0])/((double) CLOCKS_PER_SEC));
#endif
#endif
printf("\n");
#endif

/* Optional output to file */

#ifdef OUTPUT
outputData("output.csv", DD, DR, RR, omega);
#endif

/* Memory clean-up */

clReleaseMemObject(ascension);
clReleaseMemObject(ascension2);
clReleaseMemObject(declination);
clReleaseMemObject(declination2);
clReleaseMemObject(separation);
clReleaseMemObject(separation2);
clReleaseMemObject(separation3);
clReleaseProgram(program);
clReleaseKernel(kernel);
clReleaseCommandQueue(queue);
clReleaseContext(context);
delete[] dataAsc;
delete[] dataDec;
delete[] randAsc;
delete[] randDec;

return 0;
}

Compiled with -I"$(AMDAPPSDKROOT)/include" -L"$(AMDAPPSDKROOT)/lib/x86" -LOpenCL -O3

Add -DDATA_SIZE=N to use the first N galaxies.

Add -DTEST to also run sequential CPU version. Produces seven columns, the first six are pairs of histograms made on GPU and CPU respectively. The last column contain boolean values that check if the elements of each pair are identical.

Galaxy data can be found here. Use the 100k lists.
Logged
"Deliver yesterday, code today, think tomorrow."
Ceterum censeo Unionem Europaeam esse delendam.
Future supplanter of humanity.

BlackHeartKabal

  • Bay Watcher
  • You are doomed, doomed, I tell you!
    • View Profile
Re: if self.isCoder(): post() #Programming Thread
« Reply #9174 on: March 02, 2016, 09:16:36 pm »

PTW
Logged

Telgin

  • Bay Watcher
  • Professional Programmer
    • View Profile
Re: if self.isCoder(): post() #Programming Thread
« Reply #9175 on: March 02, 2016, 09:35:28 pm »

I don't have an OpenCL runtime on this computer so I can't test your program, and it's been a very long time since I've fooled with OpenCL, but I don't see anything obviously wrong.

Does the OpenCL runtime zero initialize memory buffers when you create them?  I seem to recall that it doesn't and don't see where you're zeroing the separation buffer, so that could cause it... but then I'd expect pretty inconsistent behavior, not what you're getting.

If you were sending the array size to the kernel then I'd suspect you were clobbering memory by copying the list length over the first element, but it doesn't look like you are sending it as an argument anywhere.  This does smell a lot like pointers gone wrong somewhere, but I don't see anything obviously wrong.  As far as I can tell all of the buffer creation, reads and writes are done correctly.

What happens if you try writing some specific value to separation[0] at the end of your kernel?  Is it still the list length or does it take the new value?
Logged
Through pain, I find wisdom.

da_nang

  • Bay Watcher
  • Argonian Overlord
    • View Profile
Re: if self.isCoder(): post() #Programming Thread
« Reply #9176 on: March 03, 2016, 02:24:52 am »

Yeah, nope, setting separation[0] = 0; at the end of the kernel didn't change it all. It's still the list length.
Logged
"Deliver yesterday, code today, think tomorrow."
Ceterum censeo Unionem Europaeam esse delendam.
Future supplanter of humanity.

EnigmaticHat

  • Bay Watcher
  • I vibrate, I die, I vibrate again
    • View Profile
Re: if self.isCoder(): post() #Programming Thread
« Reply #9177 on: March 03, 2016, 06:58:10 am »

I'm making a game game, and I've got values that I would like to be able to store in an excel spreadsheet for ease of editing/viewing.  Anyone know an easy way to access an excel spreadsheet in C#?  I've Googled it for a while and nothing jumped out at me as particularly easy to implement.
Logged
"T-take this non-euclidean geometry, h-humanity-baka. I m-made it, but not because I l-li-l-like you or anything! I just felt s-sorry for you, b-baka."
You misspelled seance.  Are possessing Draignean?  Are you actually a ghost in the shell? You have to tell us if you are, that's the rule

Rose

  • Bay Watcher
  • Resident Elf
    • View Profile
Re: if self.isCoder(): post() #Programming Thread
« Reply #9178 on: March 03, 2016, 07:07:44 am »

What you want is a CSV file.

Just make a text file, but put a comma between each cell, and a newline for each row, and save it with .csv extension.

Logged

EnigmaticHat

  • Bay Watcher
  • I vibrate, I die, I vibrate again
    • View Profile
Re: if self.isCoder(): post() #Programming Thread
« Reply #9179 on: March 03, 2016, 07:10:37 am »

What you want is a CSV file.

Just make a text file, but put a comma between each cell, and a newline for each row, and save it with .csv extension.
Thankye, that'll do nicely.
Logged
"T-take this non-euclidean geometry, h-humanity-baka. I m-made it, but not because I l-li-l-like you or anything! I just felt s-sorry for you, b-baka."
You misspelled seance.  Are possessing Draignean?  Are you actually a ghost in the shell? You have to tell us if you are, that's the rule
Pages: 1 ... 610 611 [612] 613 614 ... 796