[JAVA] Memorandum: When I tried TensorFlow with Tribuo, it didn't work, so I went on a journey to find the head family and lost.

Before

2020/10/03 This is an impression at the time of writing.

The story of TensorFlow in Tribuo doesn't come up here. Not only Tribuo, but various things are tough. It's just an addictive record. This is a problem before linking TensorFlow from Tribuo.

Conclusion

TensorFlow Java must also be built with Java 7 in the latest version of the Maven Central Repository (1.15.0). I don't want to do a lot of new projects that adopt Java 7. It worked until the build with Java11, but with Java12 or later, an error occurred at runtime.

Even the latest version of TensorFlow (2.3.0) did not support Cuda11. If you want to move it forcibly, you can move it.

I forgot Tribuo. It was morning when I noticed it, and before I knew it, I forgot about Java in TensorFlow and implemented python ... After all, I don't like scripting languages.

It is possible to use GPU from TensorFlow on Windos, but Windows on WSL2 on ubuntu did not work in my environment.

Understanding the current situation

Docer Desktop for Windows does not support GPGPU

I put Linux in Docer in a Windows environment and tried to use GPU from TensorFlow, but it didn't work. In the first place, the Windows version of Docer Desktop did not support GPGPU.

I ran Docker on Ubuntu built on WSL2 on Windows, but the GPU doesn't recognize it

I put Docer in Ubuntu built on WSL2 on Windows and tried it because there was information like Haha, but it was not good in my environment. In the first place, even on Ubuntu for installing Docker, if you execute / usr / local / cuda / samples / 1_Utilities / deviceQuery / deviceQuery, 35 will be returned.

image.png

I also tried the TensorFlow image, but it didn't work either. image.png

GPU does not recognize on Ubuntu built on WSL2 on Windows

AMD:Ryzen 3700x GPU:RTX3090 OS:Windows Build 20226.rs_prerelease.200925-1415 NVIDIA GPU Computing Toolkit:CUDA11.1/CUDA10.1/CUDA10.0 CUDANN:CUDA11.1/CUDA10.1/CUDA10.0

I was able to use the GPU from Ubuntu built on WSL2 on Windows, and there was information that it actually worked, so I tried it, but all the toolkits of CUDA10 / CUDA11-0 / CUDA11-1 are my It didn't work in the environment. ~~ Because Gefoce RTX 3090? AMD's curse? ~~

When you hit DeviceQuery, error code 35 is output.

Built directly on the host OS Windows 10

If you search for this, information will come out, so I was able to build it without much trouble. I don't want to build a development environment on a host OS that is not a virtual environment because I create a virtual environment for each required environment. I wish I could use the GPU with Hyper-v on windows, but the host OS is not Windows Server, WSL2 didn't work, and only time passed.

TensorFlow Java also worked on the GPU. image.png

However, if Java 12 or later is specified, an error will occur at runtime.

image.png

Impressions

The version relationship is chaos.

Recommended Posts

Memorandum: When I tried TensorFlow with Tribuo, it didn't work, so I went on a journey to find the head family and lost.
When I tried to use a Wacom tablet with ubuntu 20.04, I didn't recognize it.
I want to download a file on the Internet using Ruby and save it locally (with caution)
I built a CentOS 8 environment with Vagrant and tried to sync_folder, but I got an error, so I solved it.
When I call the file with Class # getResource from the jar file, it becomes Not Found and it is a crappy memorandum
I didn't understand the topological sort, so I looked it up and implemented it in BFS, and then tried to solve the AtCoder problem.
[Terraform] When I try to build an Azure resource on a Windows machine, it will time out, so I solved it with Docker.
I tried to express the result of before and after of Date class with a number line
When I tried to run my own service, it failed, so I screwed it into the task scheduler
UnsupportedClassVersionError was output when I placed the .war file built with Eclipse on EC2 and executed it.
I tried to figure out the flow when performing image analysis with Vision Framework and Core ML
I don't really understand the difference between swift Error and NSError, so I tried to summarize it myself.
What I did when I was addicted to the error "Could not find XXX in any of the sources" when I added a Gem and built it
I tried to measure and compare the speed of GraalVM with JMH
When registering a new user, I got an error called ActiveRecord :: NotNullViolation and how to deal with it.
Since the du command used when the capacity is full is difficult to use, I tried wrapping it with ruby
A story when I tried to make a video by linking Processing and Resolume
What I tried when I wanted to get all the fields of a bean
I tried to make a simple game with Javafx ① "Let's find happiness game" (unfinished)
How to find the distance and angle between two points on a plane
[Rails] When transitioning to a page with link_to, move to the specified location on the page
I tried to express the phone number (landline / mobile phone) with a regular expression in Rails and write validation and test
left4dead2 I made a Docker image for the server and tried running it on GCE # 3 (I had a hard time building the server)