I am looking into openmodelica and therefore I am recreating examples from the standard library.
Under Modelica > Fluid > Examples there is the HeatingSystem model which I recreated and the simulation fails due to division by zero. The original one from the library also fails.
I have two questions:
is it just me, or is it a buggy example?
If it is not me: Can somebody help me resolve the issue using the debugger, which confuses me very much?
I am running the latest nighly (since the fedora repo only offers nightlies..) with MSL 4.0.0
Related
Why ask:
I have trained a multi-layer network to recognize some specific soundwaves. It worked perfectly well, and costed only ~1ms to work. However, when I tried to migrate it to Android, I found to my astonishment that the apk is over 1GB. I checked my model and found that it was merely 50kb.I want to turn this model into java code that works without DL4J.I don’t care performance loss since the soundwave lengths 10secs each, and I have 10secs to waste.
What have I tried & result:
reduce the maven dependency into deeplearning4j-nn.(1GB->150MB).
cut the javacpp native libraries(150MB->100MB).
try to make a reduced C++ library(I can't. C++ is beyond me).
What I want:
I want it to be smaller than 1M.
What would be helpful:
agibsonccc mentioned that "years back" there was an util for this. I'd appreciate if somebody can simply provide me with the git version(or a clone would be even better).
Though I have searched through Github and found nothing, there can be some that I have missed. If there are any related projects, even unstable ones and abandoned ones, please inform me.
some other ways.
We're using rack-test for our Cucumber specs. We've been trying to migrate over to Ruby 3 for a while now and the current issue is that the Cucumber tests crash due to rack-test using both keyword/positional args in their internal methods.
I'm up for patching it myself, but seeing how little activity there is on the repo (including PRs open for weeks/months) I fear that I'd do the work and there would be nobody to patch it.
The only alternatives I see are:
Do the work and pray there will be someone to review/merge the changes
Patch it locally & use the patched version locally from now on (yuck)
Find an alternative solution for rack-test
The last solution seems the best IMO. So, are there any alternatives?
As with all open source software, you have a few options:
Keep using the old software version (i.e. don't use ruby v3.0.0).
Hope that someone else updates the dependencies for you.
Do the update yourself.
Stop using the library.
At the moment, option 1 is totally viable; ruby 2.7 is still actively maintained, and support will probably continue until 2023-03-31. You could do this, simply hoping that option 2 becomes available soon.
The standard practice for option 3 is:
Fork the project, and make the fixes.
Open a pull request to the main repo with your fixes. Hopefully it gets merged.
In the meantime, if you need to be unblocked, reference your forked repo in other projects.
This is clearly more effort, but I wouldn't call it a "yuck" solution; not unless your changes are drastic/introduce compatibility issues with the main project, and the two branches diverge.
As for option 4, as with virtually any library replacement, there's always going to be some trade-off between compatibility/features, but clearly other testing frameworks do exist. It depends how you are actually using it. Your mileage may vary.
In summary, I can't really give an objective answer to such a subjective question, but my advice at the moment would be: If you have time/skill/motivation to update to ruby 3 right now, then fork the dependency and update it. (It's probably not a massive change needed!).
But if you lack the time/skill/motivation to do this, then just stick with ruby 2.7 for now.
i want to implement drake in my project, but i found it almost impossible.
Although there are notebooks and course explain robotics theory and how drake works,
http://underactuated.csail.mit.edu/underactuated.html?chapter=drake
https://www.edx.org/course/underactuated-robotics-mitx-6-832x-0
But how could i use the codes in drake in my project. For example, i want to simulate a 6-Dof arm using V-rep and ROS, and i want to inplement force control to the arm using "qp_inverse_dynamics" in drake, do i need to include all files that "qp_inverse_dynamics" used, and construct the build system? There are tons of files.
I have made a quadruped robot using position control and PID controller, and have a little bit experience of using open source convex quadratic programs solver(osqp)。
And now, after build and tested drake using bazel, what coule I do to use codes in drake in my project? Or should I just write my own codes using the method in Underactuated Robotics notebook?
thanks a lot.
This repository is our working example of how to use drake in your own project:
https://github.com/RobotLocomotion/drake-shambhala
We do support OSQP as one of many solver backends. There is a chance that you will find that you want some feature in drake that is not yet exposed in the binary installation, in which case please make a request on github. But I suspect it should work well for you.
N.B. The lectures you've pointed to on edX are a few years old now. The current version of the course is running right now, with streamed/recorded lectures available at http://underactuated.csail.mit.edu/Spring2018/index.html#textbook/assignments/videos
I am working on a project that uses Cinder for graphics, and for image loading, we are using FreeImage mainly for loading HDR images.
It is all working fine under windows, but now I am trying to build an OSX version I am hitting a snag.
First I tried to download and build FreeImage, but the makefiles are hopelessly outdated and do not work. I managed to fudge them and build the library, but when adding to xcode it didn't seem to link. The error was that the library was ignored because it was built with a different architecture. (I couldn't figure out how to fix this, but it is an option to go back to if all else fails).
Anyway, my next attempt was to use macports to install and build FreeImage. This all worked without error and I was able to include the library in my project.
However, the problem now it that I get many std linking errors. After searching around, it seems my problem is that freeimage was built with libstdc++, but cinder complains if I dont build my project with C++11.
So, is there any way of fixing this? Can I modify the make files macports uses to build freeimage? Or is there some other sneaky way? Any suggestions appreciated.
Sorry if this question is a bit parochial, but in my searches I have seen others with similar problems (but unfortunately few answers).
In a previous project I wrote a Firefox extensions - nothing too complex - that used xmpp4moz, an add-on for Firefox that integrates the xmpp/Jabber protocol. At that time Firefox 3.6 most the most recent one and everything worked quite well. Now with Firefox 5 xmpp4moz does produces errors, starting with
Error: Component.classes['#something/something/...'] is undefined
and naturally resulting in further 'undefined' errors. In some sense this is ok, since xmpp4moz is officially not available for Firefox 5. And given that the last update was in 2009 I don't really expect a updated version. Currently I see the following two options:
Looking for alternatives/workarounds/...; so far I haven't found anything. Any ideas?
Trying to update/modify xmpp4moz myself to make it running in Firefox 5
The thing is that at the moment I cannot really assess the required efforts.
Summing up, I'm stuck :)
The sameplace download at http://www.sameplace.cc/ appears to include a slightly newer version of xmpp4moz (I didn't really check whether install.rdf is the only difference from the source code repository however). Still, it is only compatible with Firefox 3.6. From the look of it, there are no big issues, main problem is that the XPCOM components aren't being registered. See https://developer.mozilla.org/en/XPCOM/XPCOM_changes_in_Gecko_2.0 for information on the relevant changes, usually updating the components and chrome.manifest is easy.