Hi Ruochun,

Thank you for your reply! The reason why i tryed to run 
the DEMdemoFractureBox demo is that i would like to model rock breakage in 
my case. From your paper published in Computer Physics Communications, i 
noticed that you have achieved the uniaxial compression test of rock. Could 
you share the code with us?

By the way, i have three questions needing your help.
(1) For my case, i would like to model the sliding and framentation of many 
rock blocks. So, how to generate a assembly of brakeable rock blcoks? In 
particular, how to generate a irregular shaped rock block which consists of 
sphere elements?

(2) If we finished our own code, where and how to generate a executable 
code?

(3) If we modified the DEM-Engine source code, such as if we add a force 
model, how to reconfigure the DEM-Engine?

Thank you,
Weigang

On Wednesday, May 15, 2024 at 5:36:47 PM UTC+8 Ruochun Zhang wrote:

> Most of the demos are quite large. This one particularly uses a fine step 
> size and depending on the hardware, it may take hours or days. I suggest 
> you wait longer. Or you can try out some other demos that I have 
> explanations for on the Git page.
>
> You don't necessarily need to run them. Just have a look at how the 
> methods I mentioned in the previous post are used in these demos to get an 
> idea on how you can use them.
>
> If you just want to know what a contact file may look like, then I happen 
> to have one stored in *data/sim_data/example_cnt_pairs.csv*.
>
> Thank you,
> Ruochun
>
> On Wednesday, May 15, 2024 at 4:59:37 PM UTC+8 [email protected] wrote:
>
>> Hi Ruochun:
>>
>> Thank you for your reply! 
>> When i run the demo 'DEMdemoFractureBox', the runtime inerface is always 
>> like the figure below all the time. There is nothing outputed.
>> Do you have any suggestion?
>> [image: 微信图片_20240515165515.jpg]
>>
>> On Wednesday, May 15, 2024 at 2:18:01 AM UTC+8 Ruochun Zhang wrote:
>>
>>> Hi Dr. Shen,
>>>
>>> 1. I haven't added direct vtk output for sphere/clump information. They 
>>> are now written in csv format. But you can use your own tool to convert csv 
>>> to vtk. The information you need is all there. You can specify what goes 
>>> into the output file by calling the method *SetOutputContent* like the 
>>> following
>>> *DEMSim.SetOutputContent({"VEL", "ACC"});*
>>>
>>> 2. Again, this is something you can derive from the simulation status, 
>>> but DEME does not have a one-liner to compute that. You can compute the 
>>> kinetic energy through the linear and angular velocities of each particle, 
>>> and compute the potential through the positions of each particle at 
>>> different points in time. The information can all be queried through 
>>> trackers. For the kinetic energy though, there is a convenient call to 
>>> compute that which is through inspectors
>>> *auto KE_finder = DEMSim.CreateInspector("clump_kinetic_energy");*
>>> You can find this example in the demo SingleSphereCollide.
>>>
>>> However, if you also need to know respectively the contribution of 
>>> friction and damping, this is more complex, and you need to write a custom 
>>> force model that records this information. This is an advanced usage and a 
>>> bit more challenging. I also find this not that meaningful in many 
>>> real-world DEM applications because the damping and friction coefficients 
>>> can be very heuristic anyway.
>>>
>>> 3. This can be written to a contact file. The method to use is 
>>> *WriteContactFile*. An example can be found in the demo GRCPrep_Part1 
>>> or 2 or 3. You should also specify what goes into those contact files by 
>>> calling *SetContactOutputContent*. An example...
>>> *DEMSim.SetContactOutputContent({"OWNER", "FORCE", "POINT", "COMPONENT", 
>>> "NORMAL", "TORQUE"});*
>>>
>>> If you have specific questions regarding using the methods, feel free to 
>>> ask.
>>>
>>> Thank you,
>>> Ruochun
>>> On Tuesday, May 14, 2024 at 1:52:27 PM UTC+8 [email protected] wrote:
>>>
>>>> Hi Ruochun,
>>>>
>>>> Thank you for your help again! I would like to ask some questions about 
>>>> the output data of dem-engine.
>>>> 1. how to output a vtk file in which i would like to contain the 
>>>> position, radius, velocity and resultant force of particles.
>>>> 2. how to output the energy dissipation, such as the energy dissipated 
>>>> by the interparticle friction and damping.
>>>> 3. how to output the interparticle force which  i would like to use to 
>>>> plot force chain.
>>>>
>>>> Thank you!
>>>>
>>>> On Monday, May 13, 2024 at 4:23:57 PM UTC+8 Ruochun Zhang wrote:
>>>>
>>>>> Oh right... Rebooting might be needed for completing the CUDA 
>>>>> installation, I forgot...
>>>>>
>>>>> Now you should be able to install pyDEME too, since the installation 
>>>>> environment issue is resolved.
>>>>>
>>>>> Thank you,
>>>>> Ruochun
>>>>>
>>>>> On Monday, May 13, 2024 at 4:17:01 PM UTC+8 [email protected] wrote:
>>>>>
>>>>>> Hi Ruochun,
>>>>>> After the reboot of my computer, the demo runs successfully. Thank 
>>>>>> you for your careful help!
>>>>>>
>>>>>> On Friday, May 10, 2024 at 3:06:30 PM UTC+8 Ruochun Zhang wrote:
>>>>>>
>>>>>>> Yes. This error was encountered during a *cudaGetDeviceCount *call, 
>>>>>>> which is the first GPU-related call when constructing a DEME simulation 
>>>>>>> object. So CUDA failed to get the number of devices. I don't know if 
>>>>>>> you've been having success running GPU-based applications on this 
>>>>>>> machine 
>>>>>>> but again, I suspect it can't run anything GPU-related, not limited to 
>>>>>>> DEME. Possible treatments include...
>>>>>>> 1. The NVIDIA driver installed on your system is not compatible with 
>>>>>>> CUDA 12.0, or is corrupted. You probably want to ensure a correct 
>>>>>>> installation of a GPU driver first, if you haven't paid attention to 
>>>>>>> doing 
>>>>>>> that.
>>>>>>> 2. You may want to check using *nvidia-smi* to see if the OS 
>>>>>>> recognizes the GPU at all.
>>>>>>> 3. You should ensure that you have the permissions needed to access 
>>>>>>> GPUs.
>>>>>>>
>>>>>>> In short, ensure you have GPU access. It's still good to start from 
>>>>>>> a minimal CUDA example to debug, since it appears to be a basic 
>>>>>>> environmental issue.
>>>>>>>
>>>>>>> Thank you,
>>>>>>> Ruochun
>>>>>>>
>>>>>>> On Friday, May 10, 2024 at 9:11:52 AM UTC+8 [email protected] 
>>>>>>> wrote:
>>>>>>>
>>>>>>>> Hi Ruochun,
>>>>>>>> I have succefully configured the DEME after the reinstallation of 
>>>>>>>> CUDA. Thank you! It is indeed that the  multiple times installation of 
>>>>>>>> CUDA 
>>>>>>>> induced the previours error. 
>>>>>>>> When I run the demo, there is an error like this. Do you have any 
>>>>>>>> suggestion?
>>>>>>>> [image: 微信图片_20240510091101.jpg]
>>>>>>>>
>>>>>>>> On Thursday, May 9, 2024 at 7:08:28 PM UTC+8 Ruochun Zhang wrote:
>>>>>>>>
>>>>>>>>> To me, because CMakeCUDACompilerId.cu is a Cmake-generated minimal 
>>>>>>>>> example and it failed to compile, it looks like the compiler is not 
>>>>>>>>> configured properly and cannot compile anything. The solution is 
>>>>>>>>> probably 
>>>>>>>>> case-by-case. I am not familiar with the installation process of CUDA 
>>>>>>>>> enough to accurately remote-diagnose (but someone else here might 
>>>>>>>>> be). The 
>>>>>>>>> best you can do is to write a minimal CUDA example, test if it can be 
>>>>>>>>> compiled, and debug starting from there. However, I have a couple of 
>>>>>>>>> guesses...
>>>>>>>>> 1. If you installed CUDA multiple times or had multiple trials 
>>>>>>>>> (like once from apt-get and then another time from a downloaded 
>>>>>>>>> file), 
>>>>>>>>> there can be conflicts. The nvcc in /usr/bin might be a symbolic 
>>>>>>>>> link, and 
>>>>>>>>> it could be linked against an executable that is not compatible with 
>>>>>>>>> the 
>>>>>>>>> CUDA toolkit. You might try to fix this symbolic link by linking it 
>>>>>>>>> against 
>>>>>>>>> that one in cuda-12.0/bin, or the one you think is correct.
>>>>>>>>> 2. Just remove all installation of CUDA and start over.
>>>>>>>>> 3. I don't know the GCC or Clang version you are using. It's not 
>>>>>>>>> likely, but it might be too old or too new to be compatible with 
>>>>>>>>> nvcc. GCC 
>>>>>>>>> 9.4 should be a version that works in most of my trials, in case you 
>>>>>>>>> wish 
>>>>>>>>> to give it a try.
>>>>>>>>>
>>>>>>>>> That is all I can think of at this point, thank you,
>>>>>>>>> Ruochun
>>>>>>>>> On Thursday, May 9, 2024 at 4:54:34 PM UTC+8 [email protected] 
>>>>>>>>> wrote:
>>>>>>>>>
>>>>>>>>>> After press c to configure, there is also an error like this:
>>>>>>>>>> [image: 5c8b56934e5f50fa728c05edc5b5ffd.jpg]
>>>>>>>>>>
>>>>>>>>>> On Thursday, May 9, 2024 at 2:27:59 PM UTC+8 Ruochun Zhang wrote:
>>>>>>>>>>
>>>>>>>>>>> Can you please press c to configure the project, so we might 
>>>>>>>>>>> know what is still missing for the project? If nothing goes wrong, 
>>>>>>>>>>> then try 
>>>>>>>>>>> pressing g to generate the project.
>>>>>>>>>>>
>>>>>>>>>>> Thank you,
>>>>>>>>>>> Ruochun
>>>>>>>>>>>
>>>>>>>>>>> On Thursday, May 9, 2024 at 10:11:05 AM UTC+8 
>>>>>>>>>>> [email protected] wrote:
>>>>>>>>>>>
>>>>>>>>>>>> I updated the cmake from 3.20 to 3.29, which made it find the 
>>>>>>>>>>>> nvcc. However, the ccmake GUI is empty now.
>>>>>>>>>>>> [image: 微信图片_20240509100541.jpg]
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>> On Thursday, May 9, 2024 at 3:36:40 AM UTC+8 Ruochun Zhang 
>>>>>>>>>>>> wrote:
>>>>>>>>>>>>
>>>>>>>>>>>> It looks like it found the compiler nvcc this time, but it's 
>>>>>>>>>>>> not working correctly... How did you make it find nvcc in 
>>>>>>>>>>>> */usr/bin* this time? I thought you had nvcc in another 
>>>>>>>>>>>> location last time. You re-installed? And can you show the ccmake 
>>>>>>>>>>>> GUI this 
>>>>>>>>>>>> time as well?
>>>>>>>>>>>>
>>>>>>>>>>>> Ruochun
>>>>>>>>>>>>
>>>>>>>>>>>> On Wednesday, May 8, 2024 at 5:16:58 PM UTC+8 
>>>>>>>>>>>> [email protected] wrote:
>>>>>>>>>>>>
>>>>>>>>>>>> Hi Dr. Zhang,
>>>>>>>>>>>>
>>>>>>>>>>>> I still encountered a error like this. Do you have any 
>>>>>>>>>>>> suggestion?
>>>>>>>>>>>>
>>>>>>>>>>>> Thanks!
>>>>>>>>>>>> [image: a391d46ae4497f81bd18b7e111b4842.jpg]
>>>>>>>>>>>> On Tuesday, May 7, 2024 at 8:20:57 PM UTC+8 Ruochun Zhang wrote:
>>>>>>>>>>>>
>>>>>>>>>>>> Doesn't look like it finds a CUDA compiler at all. It appears 
>>>>>>>>>>>> that /usr/bin is checked but it's not found there. Please make 
>>>>>>>>>>>> sure your 
>>>>>>>>>>>> CUDA installation is in PATH. Maybe the troubleshooting part of 
>>>>>>>>>>>> this 
>>>>>>>>>>>> section 
>>>>>>>>>>>> <https://github.com/projectchrono/DEM-Engine?tab=readme-ov-file#compilation>
>>>>>>>>>>>>  
>>>>>>>>>>>> of DEME manual can help you.
>>>>>>>>>>>>
>>>>>>>>>>>> Thank you,
>>>>>>>>>>>> Ruochun
>>>>>>>>>>>>
>>>>>>>>>>>> On Tuesday, May 7, 2024 at 7:14:18 PM UTC+8 [email protected] 
>>>>>>>>>>>> wrote:
>>>>>>>>>>>>
>>>>>>>>>>>> The ccmake GUI and the configure error are shown below. I do 
>>>>>>>>>>>> not see anything related to  CUDA_ARCHITECTURES or CUDA_PATH.
>>>>>>>>>>>> [image: 微信图片_20240507191053.jpg] [image: 
>>>>>>>>>>>> 微信图片_20240507191047.jpg]
>>>>>>>>>>>>
>>>>>>>>>>>> On Tuesday, May 7, 2024 at 6:12:11 PM UTC+8 Ruochun Zhang wrote:
>>>>>>>>>>>>
>>>>>>>>>>>> Looks all good. Please show your ccmake GUI when configuring 
>>>>>>>>>>>> the project: You may see in there a few missing items that the 
>>>>>>>>>>>> autodetection failed to identify. Could be CUDA_ARCHITECTURES or 
>>>>>>>>>>>> CUDA_PATH 
>>>>>>>>>>>> related.
>>>>>>>>>>>> If this is the case, then we may help you fill them out 
>>>>>>>>>>>> manually.
>>>>>>>>>>>>
>>>>>>>>>>>> Ruochun
>>>>>>>>>>>> On Tuesday, May 7, 2024 at 5:23:14 PM UTC+8 [email protected] 
>>>>>>>>>>>> wrote:
>>>>>>>>>>>>
>>>>>>>>>>>> Hi Dr. Zhang:
>>>>>>>>>>>>
>>>>>>>>>>>> The versions of cmake and cuda, and the model of GPU are shown 
>>>>>>>>>>>> below.
>>>>>>>>>>>>
>>>>>>>>>>>> Thank you!
>>>>>>>>>>>> [image: 微信图片_20240507171644.jpg]
>>>>>>>>>>>>
>>>>>>>>>>>> On Tuesday, May 7, 2024 at 4:50:27 PM UTC+8 Ruochun Zhang wrote:
>>>>>>>>>>>>
>>>>>>>>>>>> Hi Dr. Shen,
>>>>>>>>>>>>
>>>>>>>>>>>> A couple of questions: What is your cmake version, what is your 
>>>>>>>>>>>> CUDA version, and what model is the GPU you have on your system?
>>>>>>>>>>>>
>>>>>>>>>>>> Thank you,
>>>>>>>>>>>> Ruochun
>>>>>>>>>>>>
>>>>>>>>>>>> On Tuesday, May 7, 2024 at 8:37:47 AM UTC+8 [email protected] 
>>>>>>>>>>>> wrote:
>>>>>>>>>>>>
>>>>>>>>>>>> Hello everyone,
>>>>>>>>>>>>
>>>>>>>>>>>> When i build the c++ DEME, there is an error as shown in the 
>>>>>>>>>>>> figure below.
>>>>>>>>>>>>
>>>>>>>>>>>> Coould anyone give me a help?
>>>>>>>>>>>>
>>>>>>>>>>>> Thanks![image: 微信图片_20240507083122.jpg]
>>>>>>>>>>>>
>>>>>>>>>>>>

-- 
You received this message because you are subscribed to the Google Groups 
"ProjectChrono" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/projectchrono/23027df8-326a-4c74-a25f-4b1c69a16b18n%40googlegroups.com.

Reply via email to