[Boards: 3 / a / aco / adv / an / asp / b / bant / biz / c / can / cgl / ck / cm / co / cock / d / diy / e / fa / fap / fit / fitlit / g / gd / gif / h / hc / his / hm / hr / i / ic / int / jp / k / lgbt / lit / m / mlp / mlpol / mo / mtv / mu / n / news / o / out / outsoc / p / po / pol / qa / qst / r / r9k / s / s4s / sci / soc / sp / spa / t / tg / toy / trash / trv / tv / u / v / vg / vint / vip / vp / vr / w / wg / wsg / wsr / x / y ] [Search | Free Show | Home]

Scripting using a GPU

This is a blue board which means that it's for everybody (Safe For Work content only). If you see any adult content, please report it.

Thread replies: 16
Thread images: 1

File: gpu.jpg (742KB, 1200x1499px) Image search: [Google]
gpu.jpg
742KB, 1200x1499px
How would I go about running a Python script involving strings on a NVIDIA GPU with Linux? I'm aware of PyCUDA, Numba, and PyOpenCL but it appears these can only be used for float/int data types. If I'm mistaken about this, I would love to be corrected.

It seems odd to be that there is no easy way to just run a script on a GPU with CUDA/OpenCL, regardless of what data types are used.

Help me out here, /g/.
>>
>>61311987
Why exactly do you need to run a python script on a GPU?
>>
>>61312030
I'm doing security work requiring billions of guesses a second which necessitates computation on a GPU.

Meant to include in the OP: Any other strategies on how to do this without a GPU are also welcome.
>>
GPUs are not exactly like CPUs in the sense that you can just "run" a program on them. You have to write your program with a library like https://developer.nvidia.com/pycuda to send work to the GPU from the normal execution environment.
>>
>>61312163
And those libraries can definitely work with strings or other data types. See https://stackoverflow.com/questions/31237286/making-a-multi-processor-string-evaluation-algorithm just for one example.
>>
>>61312241
This is helpful, thanks. I need to include some libraries for hashing so I'm thinking the only way to do this efficiently (or at all) is to re-write the script in C and run it with CUDA the old fashioned way
>>
Any other high-performance computing methods anyone knows about? I read something about using rainbow tables and an SSD somewhere I think
>>
Why are you trying to use a GPU to bruteforce encryption?
>>
>>61314378
Because I watched this video:
https://www.youtube.com/watch?v=7U-RbOKanYs

Obviously I'm new to this. What's the preferred method?
>>
>>61314519
bump, interested to hear a response to this
>>
Remember that strings are really just numbers.
Example:
Text:
Say Hello to My Little Friend

Hex:
5361792048656c6c6f20746f204d79204c6974746c6520467269656e64

You can append a letter by shifting left (x<<2) and adding(x+=51)
You can remove a letter by shifting right (x>>2)
You can extend appending a string by using the append letter function.
You can access each letter by diving and getting the rest of the string by modding
text[0] == 53
text[0..<n] == 61792048656c6c6f20746f204d79204c6974746c6520467269656e64

Just make your library to do the normal getter, setter, manipulators, etc using numbers.

Made this up...Don't know what the fuck I'm talking about...so don't quote me...
>>
>>61311987
>running a python script on an nvidia GPU
Why would you want this??
Just learn cuda and make interfaces for the scripts
>>
>>61316078
Correct, this occurred to me after making the post. According to >>61312241 it's not even an issue

>>61316270
You're right, it's a pain in the ass and probably not feasible anyway for my purposes. Cuda is the way to go

>>61314378
Again, I ask: was this guy memeing or is there a better way? It's not a particularly large keyspace at all. I'd rather not go the route of rainbow tables because I don't have 4+ terabytes of free space at my disposal, at least not right now
>>
>>61312062
>trying to brute force a porn.rar
>>
>>61311987
hey OP, if you can't into CUDA but can into multithreading, why not just buy some time on a supercomputer? It's not that expensive and writing code for it is - relatively - easier
>>
>>61316078
what a wonderful way to overflow ints.
Thread posts: 16
Thread images: 1


[Boards: 3 / a / aco / adv / an / asp / b / bant / biz / c / can / cgl / ck / cm / co / cock / d / diy / e / fa / fap / fit / fitlit / g / gd / gif / h / hc / his / hm / hr / i / ic / int / jp / k / lgbt / lit / m / mlp / mlpol / mo / mtv / mu / n / news / o / out / outsoc / p / po / pol / qa / qst / r / r9k / s / s4s / sci / soc / sp / spa / t / tg / toy / trash / trv / tv / u / v / vg / vint / vip / vp / vr / w / wg / wsg / wsr / x / y] [Search | Top | Home]

I'm aware that Imgur.com will stop allowing adult images since 15th of May. I'm taking actions to backup as much data as possible.
Read more on this topic here - https://archived.moe/talk/thread/1694/


If you need a post removed click on it's [Report] button and follow the instruction.
DMCA Content Takedown via dmca.com
All images are hosted on imgur.com.
If you like this website please support us by donating with Bitcoins at 16mKtbZiwW52BLkibtCr8jUg2KVUMTxVQ5
All trademarks and copyrights on this page are owned by their respective parties.
Images uploaded are the responsibility of the Poster. Comments are owned by the Poster.
This is a 4chan archive - all of the content originated from that site.
This means that RandomArchive shows their content, archived.
If you need information for a Poster - contact them.