- 使用 Spring Initializr 创建 Spring Boot 应用程序
- 在Spring Boot中配置Cassandra
- 在 Spring Boot 上配置 Tomcat 连接池
- 将Camel消息路由到嵌入WildFly的Artemis上
本文整理了Java中us.ihmc.robotics.math.frames.YoFramePointInMultipleFrames
类的一些代码示例,展示了YoFramePointInMultipleFrames
类的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。YoFramePointInMultipleFrames
类的具体详情如下:
包路径:us.ihmc.robotics.math.frames.YoFramePointInMultipleFrames
类名称:YoFramePointInMultipleFrames
暂无
代码示例来源:origin: us.ihmc/ihmc-robotics-toolkit
public ConstantPoseTrajectoryGenerator(String namePrefix, boolean allowMultipleFrames, ReferenceFrame referenceFrame, YoVariableRegistry parentRegistry)
{
this.allowMultipleFrames = allowMultipleFrames;
YoVariableRegistry registry = new YoVariableRegistry(namePrefix + getClass().getSimpleName());
YoFramePointInMultipleFrames yoFramePointInMultipleFrames = new YoFramePointInMultipleFrames(namePrefix + "ConstantPosition", registry, referenceFrame);
position = yoFramePointInMultipleFrames;
YoFrameQuaternionInMultipleFrames yoFrameQuaternionInMultiplesFrames = new YoFrameQuaternionInMultipleFrames(namePrefix + "ConstantOrientation",
registry, referenceFrame);
orientation = yoFrameQuaternionInMultiplesFrames;
multipleFramesHolders = new ArrayList<YoMultipleFramesHolder>();
multipleFramesHolders.add(yoFramePointInMultipleFrames);
multipleFramesHolders.add(yoFrameQuaternionInMultiplesFrames);
}
代码示例来源:origin: us.ihmc/CommonWalkingControlModules
public void setInitialPosition(double x, double y, double z)
{
this.initialPosition.set(x, y, z);
}
代码示例来源:origin: us.ihmc/CommonWalkingControlModules
private void setCornerPointsToNaN()
{
for (int i = 0; i < entryCornerPoints.size(); i++)
entryCornerPoints.get(i).setToNaN();
for (int i = 0; i < exitCornerPoints.size(); i++)
exitCornerPoints.get(i).setToNaN();
}
代码示例来源:origin: us.ihmc/ihmc-robotics-toolkit-test
@ContinuousIntegrationTest(estimatedDuration = 0.0)
@Test(timeout=300000)
public void testChangeToRegisteredFrame()
{
YoVariableRegistry registry = new YoVariableRegistry("youhou");
YoFramePointInMultipleFrames yoFramePointInMultipleFrames = new YoFramePointInMultipleFrames("blop", registry, new ReferenceFrame[]{worldFrame, frameA});
yoFramePointInMultipleFrames.switchCurrentReferenceFrame(worldFrame);
FramePoint3D framePoint = new FramePoint3D(worldFrame);
Point3D point = RandomGeometry.nextPoint3D(random, 100.0, 100.0, 100.0);
yoFramePointInMultipleFrames.set(point);
framePoint.set(point);
yoFramePointInMultipleFrames.changeFrame(frameA);
framePoint.changeFrame(frameA);
assertTrue(framePoint.epsilonEquals(yoFramePointInMultipleFrames, 1e-10));
try
{
yoFramePointInMultipleFrames.changeFrame(frameB);
fail("Should have thrown an exception");
}
catch (Exception e)
{
// Good
}
}
代码示例来源:origin: us.ihmc/CommonWalkingControlModules
initialPosition = new YoFramePointInMultipleFrames(namePrefix + "InitialPosition", registry, referenceFrame);
finalPosition = new YoFramePointInMultipleFrames(namePrefix + "FinalPosition", registry, referenceFrame);
currentPosition = new YoFramePointInMultipleFrames(namePrefix + "CurrentPosition", registry, referenceFrame);
currentVelocity = new YoFrameVectorInMultipleFrames(namePrefix + "CurrentVelocity", registry, referenceFrame);
currentAcceleration = new YoFrameVectorInMultipleFrames(namePrefix + "CurrentAcceleration", registry, referenceFrame);
initialPosition.buildUpdatedYoFramePointForVisualizationOnly(), initialOrientationForViz, 0.1);
final YoGraphicCoordinateSystem finalPoseViz = new YoGraphicCoordinateSystem(namePrefix + "FinalPose",
finalPosition.buildUpdatedYoFramePointForVisualizationOnly(), finalOrientationForViz, 0.1);
final YoGraphicCoordinateSystem currentPoseViz = new YoGraphicCoordinateSystem(namePrefix + "CurrentPose",
currentPosition.buildUpdatedYoFramePointForVisualizationOnly(), currentOrientationForViz, 0.25);
yoGraphicsList = new YoGraphicsList(namePrefix + "StraightLineTrajectory");
yoGraphicsList.add(currentPositionViz);
代码示例来源:origin: us.ihmc/ihmc-robotics-toolkit-test
YoFramePointInMultipleFrames yoFramePointInMultipleFrames = new YoFramePointInMultipleFrames("blop", registry, worldFrame);
assertEquals(1, yoFramePointInMultipleFrames.getNumberOfReferenceFramesRegistered());
yoFramePointInMultipleFrames.getRegisteredReferenceFrames(referenceFrames);
yoFramePointInMultipleFrames.registerReferenceFrame(worldFrame);
yoFramePointInMultipleFrames.registerReferenceFrame(frameA);
assertEquals(2, yoFramePointInMultipleFrames.getNumberOfReferenceFramesRegistered());
yoFramePointInMultipleFrames.getRegisteredReferenceFrames(referenceFrames);
代码示例来源:origin: us.ihmc/ihmc-robotics-toolkit-test
@ContinuousIntegrationTest(estimatedDuration = 0.0)
@Test(timeout=300000)
public void testSetIncludingFrame()
{
YoVariableRegistry registry = new YoVariableRegistry("youhou");
YoFramePointInMultipleFrames yoFramePointInMultipleFrames = new YoFramePointInMultipleFrames("blop", registry, new ReferenceFrame[]{worldFrame, frameA});
yoFramePointInMultipleFrames.switchCurrentReferenceFrame(worldFrame);
FramePoint3D framePoint = EuclidFrameRandomTools.nextFramePoint3D(random, frameA, -100.0, 100.0, -100.0, 100.0, -100.0, 100.0);
yoFramePointInMultipleFrames.setIncludingFrame(framePoint);
assertTrue(framePoint.epsilonEquals(yoFramePointInMultipleFrames, 1e-10));
try
{
yoFramePointInMultipleFrames.setIncludingFrame(new FramePoint3D(frameC));
fail("Should have thrown an exception");
}
catch (Exception e)
{
// Good
}
}
}
代码示例来源:origin: us.ihmc/CommonWalkingControlModules
public void initialize()
{
tangentialPlane.update();
currentTrajectoryFrame = initialPosition.getReferenceFrame();
changeFrame(tangentialPlane, false);
currentTime.set(0.0);
MathTools.checkIfInRange(trajectoryTime.getDoubleValue(), 0.0, Double.POSITIVE_INFINITY);
double tIntermediate = leaveTime.getDoubleValue();
xyPolynomial.setCubic(tIntermediate, trajectoryTime.getDoubleValue(), 0.0, 0.0, 1.0, 0.0);
double z0 = initialPosition.getZ();
double zIntermediate = initialPosition.getZ() + leaveDistance.getDoubleValue();
double zf = finalPosition.getZ();
zPolynomial.setSexticUsingWaypoint(0.0, tIntermediate, trajectoryTime.getDoubleValue(), z0, 0.0, 0.0, zIntermediate, zf, 0.0, 0.0);
currentPosition.set(initialPosition);
currentVelocity.setToZero();
currentAcceleration.setToZero();
changeFrame(currentTrajectoryFrame, false);
if (visualize)
visualizeTrajectory();
}
代码示例来源:origin: us.ihmc/CommonWalkingControlModules
YoFramePointInMultipleFrames entryConstantCMP = new YoFramePointInMultipleFrames(namePrefix + "EntryCMP" + i, parentRegistry, framesToRegister);
entryConstantCMP.setToNaN();
entryCMPs.add(entryConstantCMP);
entryCMPsInWorldFrameReadOnly.add(entryConstantCMP.buildUpdatedYoFramePointForVisualizationOnly());
YoFramePointInMultipleFrames exitConstantCMP = new YoFramePointInMultipleFrames(namePrefix + "ExitCMP" + i, parentRegistry, framesToRegister);
exitConstantCMP.setToNaN();
exitCMPs.add(exitConstantCMP);
exitCMPsInWorldFrameReadOnly.add(exitConstantCMP.buildUpdatedYoFramePointForVisualizationOnly());
代码示例来源:origin: us.ihmc/IHMCRoboticsToolkit
public YoFramePoint buildUpdatedYoFramePointForVisualizationOnly()
{
if (yoFramePointInWorld == null)
{
final ReferenceFrame worldFrame = ReferenceFrame.getWorldFrame();
if (!isReferenceFrameRegistered(worldFrame))
registerReferenceFrame(worldFrame);
yoFramePointInWorld = new YoFramePoint(namePrefix, worldFrame.getName(), worldFrame, registry);
attachVariableChangedListener(new VariableChangedListener()
{
private final FramePoint localFramePoint = new FramePoint();
private final YoFramePoint point = yoFramePointInWorld;
@Override
public void variableChanged(YoVariable<?> v)
{
getFrameTupleIncludingFrame(localFramePoint);
point.setAndMatchFrame(localFramePoint);
}
});
}
return yoFramePointInWorld;
}
代码示例来源:origin: us.ihmc/CommonWalkingControlModules
@Override
public String toString()
{
String ret = "";
ReferenceFrame currentFrame = initialPosition.getReferenceFrame();
ret += "Current time: " + currentTime.getDoubleValue() + ", trajectory time: " + trajectoryTime.getDoubleValue();
ret += "\nCurrent position: " + currentPosition.toStringForASingleReferenceFrame(currentFrame);
ret += "\nCurrent velocity: " + currentVelocity.toStringForASingleReferenceFrame(currentFrame);
ret += "\nCurrent acceleration: " + currentAcceleration.toStringForASingleReferenceFrame(currentFrame);
return ret;
}
}
代码示例来源:origin: us.ihmc/CommonWalkingControlModules
private void computeFinalCMPBetweenSupportFeet(int cmpIndex, FrameConvexPolygon2d footA, FrameConvexPolygon2d footB)
{
footA.getCentroid(tempCentroid);
firstCMP.setXYIncludingFrame(tempCentroid);
firstCMP.changeFrame(worldFrame);
footB.getCentroid(tempCentroid);
secondCMP.setXYIncludingFrame(tempCentroid);
secondCMP.changeFrame(worldFrame);
upcomingSupport.clear(worldFrame);
tempFootPolygon.setIncludingFrame(footA);
tempFootPolygon.changeFrameAndProjectToXYPlane(worldFrame);
upcomingSupport.addVertices(tempFootPolygon);
tempFootPolygon.setIncludingFrame(footB);
tempFootPolygon.changeFrameAndProjectToXYPlane(worldFrame);
upcomingSupport.addVertices(tempFootPolygon);
upcomingSupport.update();
entryCMPs.get(cmpIndex).switchCurrentReferenceFrame(worldFrame);
exitCMPs.get(cmpIndex).switchCurrentReferenceFrame(worldFrame);
upcomingSupport.getCentroid(tempCentroid);
tempCentroid3d.setXYIncludingFrame(tempCentroid);
double chicken = MathTools.clipToMinMax(percentageChickenSupport.getDoubleValue(), 0.0, 1.0);
if (chicken <= 0.5)
entryCMPs.get(cmpIndex).interpolate(firstCMP, tempCentroid3d, chicken * 2.0);
else
entryCMPs.get(cmpIndex).interpolate(tempCentroid3d, secondCMP, (chicken-0.5) * 2.0);
exitCMPs.get(cmpIndex).set(entryCMPs.get(cmpIndex));
}
代码示例来源:origin: us.ihmc/CommonWalkingControlModules
public void setInitialPose(FramePose initialPose)
{
initialPose.getPoseIncludingFrame(tempPosition, tempOrientation);
tempPosition.changeFrame(initialPosition.getReferenceFrame());
initialPosition.set(tempPosition);
tempOrientation.changeFrame(initialOrientation.getReferenceFrame());
initialOrientation.set(tempOrientation);
initialOrientationForViz.setAndMatchFrame(tempOrientation);
}
代码示例来源:origin: us.ihmc/CommonWalkingControlModules
@Override
public void getPosition(FramePoint positionToPack)
{
currentPosition.getFrameTupleIncludingFrame(positionToPack);
}
代码示例来源:origin: us.ihmc/ihmc-robotics-toolkit-test
@ContinuousIntegrationTest(estimatedDuration = 0.0)
@Test(timeout=300000)
public void testSetToZero()
{
YoVariableRegistry registry = new YoVariableRegistry("youhou");
YoFramePointInMultipleFrames yoFramePointInMultipleFrames = new YoFramePointInMultipleFrames("blop", registry, allFrames);
yoFramePointInMultipleFrames.switchCurrentReferenceFrame(worldFrame);
FramePoint3D framePoint = new FramePoint3D(worldFrame);
framePoint.setToZero(worldFrame);
assertTrue(framePoint.epsilonEquals(yoFramePointInMultipleFrames, 1e-10));
}
代码示例来源:origin: us.ihmc/IHMCRoboticsToolkit
@Override
public void changeFrame(ReferenceFrame desiredFrame)
{
get(point);
ReferenceFrame currentReferenceFrame = multipleFramesHelper.switchCurrentReferenceFrame(desiredFrame);
framePoint.setIncludingFrame(currentReferenceFrame, point);
framePoint.changeFrame(desiredFrame);
framePoint.get(point);
set(point);
}
代码示例来源:origin: us.ihmc/CommonWalkingControlModules
List<YoFramePoint> exitCMPs = referenceCMPsCalculator.getExitCMPs();
switchCornerPointsToWorldFrame();
singleSupportInitialICP.switchCurrentReferenceFrame(worldFrame);
singleSupportFinalICP.switchCurrentReferenceFrame(worldFrame);
singleSupportInitialICP.setIncludingFrame(actualICPToHold);
singleSupportFinalICP.setIncludingFrame(actualICPToHold);
singleSupportInitialICPVelocity.set(0.0, 0.0, 0.0);
setCornerPointsToNaN();
singleSupportInitialICP.setIncludingFrame(entryCMPs.get(0));
singleSupportFinalICP.setIncludingFrame(singleSupportInitialICP);
singleSupportInitialICPVelocity.set(0.0, 0.0, 0.0);
setCornerPointsToNaN();
swingTimeSplitFraction.getDoubleValue(), transferTimeSplitFraction.getDoubleValue(), omega0);
computeDesiredCapturePointPosition(omega0, timeToSpendOnExitCMPBeforeNextDoubleSupport, exitCornerPoints.get(1), exitCMPs.get(1), singleSupportFinalICP);
exitCornerPoints.get(0).changeFrame(initialFrame);
exitCornerPoints.get(1).changeFrame(finalFrame);
entryCornerPoints.get(0).changeFrame(initialFrame);
entryCornerPoints.get(1).changeFrame(finalFrame);
changeFrameOfRemainingCornerPoints(2, worldFrame);
isHoldingPosition.set(false);
singleSupportInitialICP.changeFrame(finalFrame);
singleSupportFinalICP.changeFrame(worldFrame);
代码示例来源:origin: us.ihmc/CommonWalkingControlModules
entryCMPs.get(cmpIndex).setToNaN();
entryCMPs.get(cmpIndex).setIncludingFrame(cmp);
exitCMPs.get(cmpIndex).setIncludingFrame(cmp);
cmpIndex++;
entryCMPs.get(cmpIndex).setIncludingFrame(cmp);
firstEntryCMPForSingleSupport.setByProjectionOntoXYPlaneIncludingFrame(cmp);
computeFootstepCentroid(centroidOfUpcomingFootstep, upcomingFootsteps.get(0));
computeExitCMPForSupportFoot(cmp, transferToSide, centroidOfUpcomingFootstep, isUpcomingFootstepLast);
cmp.changeFrame(transferToSoleFrame);
exitCMPs.get(cmpIndex).setIncludingFrame(cmp);
cmpIndex++;
代码示例来源:origin: us.ihmc/CommonWalkingControlModules
currentPosition.set(finalPosition);
currentVelocity.setToZero();
currentAcceleration.setToZero();
currentPosition.interpolate(initialPosition, finalPosition, quinticParameterPolynomial.getPosition());
currentVelocity.subAndScale(alphaVel, finalPosition, initialPosition);
currentAcceleration.subAndScale(alphaAcc, finalPosition, initialPosition);
代码示例来源:origin: us.ihmc/CommonWalkingControlModules
singleSupportInitialICP.switchCurrentReferenceFrame(worldFrame);
singleSupportFinalICP.switchCurrentReferenceFrame(worldFrame);
icpSingleSupportTrajectoryGenerator.initialize();
exitCornerPoints.get(0).changeFrame(supportSoleFrame);
singleSupportInitialICP.changeFrame(supportSoleFrame);
entryCornerPoints.get(0).changeFrame(supportSoleFrame);
singleSupportFinalICP.changeFrame(worldFrame);
changeFrameOfRemainingCornerPoints(1, worldFrame);
最近,我在 XCode 上的调试器停止正常工作,并给出了以下错误: 此帧内的前一帧(gdb 无法展开超过此帧) 我已经浏览过 SO 的另一个线程,谈论丢失的符号。我通过删除符号目录并让它从 iPod
当我在设备上遇到断点时,出现以下调试器错误: 来自调试器的错误:此帧内的上一帧(gdb 无法展开超过此帧) 当应用程序遇到断点时,就会发生这种情况。如果我点击调试器中的继续按钮,它会愉快地继续,直到下
如何在 WinRT XAML 应用程序中操作框架的历史记录? 用户将从我的中心页面开始,他们可以在其中选择一个现有项目以转到其编辑屏幕,或者他们可以选择“新项目”。 “新项目”将引导他们完成一个简短的
2 帧,我希望第 2 帧“覆盖”/更新第 1 帧。基本上,其中 Table1-colB-value = Table2-oldB-value,用 Table2-newB-value 覆盖 Table1-
我正在尝试逐帧动画,但它给了我一个强制关闭,我不确定为什么它给我一个强制关闭。在我看来一切都很好。 这是我的代码,我希望有人能帮忙吗?提前致谢。 动画测试.java import android.ap
这是我的主课。 package pomsystem; public class POMSystem { public static void main(String[] args) {
如果为TRUE,我想从函数返回一个data.frame,否则使用return(ifelse(condition, mydf, NA)) 返回NA 但是, ifelse 会从 data.frame 中删
我正在处理两个 csv 文件并导入为数据框 df1 和 df2 df1 有 50000 行,df2 有 150000 行。 我想比较(遍历每一行)df2 的“时间”df1,求时间差,返回所有列的值对应
我将许多文件夹中的小文本文件读取到一个列表中。因此,我有一个长度为 n 的列表,其中包含 2 个 data.frames。 这是列表元素 3 的示例(在问题末尾输入) ip_list[[3]] $`d
为了找出数据框 df.a 是否是数据框 df.b 的子集,我做了以下操作: df.a semi_join(df.b, df.a) Joining by: c("x", "y") x y 1 1
在某些情况下,出于实现原因,我有一个只包含一个列的 data.frame df=as.data.frame(alpha=1:15) 如果我现在使用 df[-1, ] 它返回一个向量,但我想将它保留为一
Windows 8.1 商店应用中的 Frame.Navigate() 和 this.Frame.Navigate() 有什么区别? 这有什么区别 Frame.Navigate(typeof(Logi
我有两个 data.frames (df1, df2),我想用 df1$V2 的值替换 P1-P10 列中的字母值,但保留前两列df2. df1 = data.frame(V1=LETTERS, V2
有没有更好的方法来制作与现有 data.frame 具有相同维度、列名和行名的空白 data.frame? BAM<-read.table(~/myfile) # 10 rows and 10 co
我有一个列表 data.frame s。例如 set.seed(1) my_list result.df id var_p var_m var_d var_a
假设我有两个数据框 df1 和 df2 如下 Df1 Id Price Profit Month 10 5 2 1 10 5 3 2 10 5 2
我将创建一个网站,除了它自己的内容之外,它还将链接(在 iframe 中)到世界最大的报纸网站,如纽约时报、金融时报和其他一些网站。 但是我遇到了框架许可的问题。例如,纽约时报向我展示了一个错误 Lo
假设我有一个 data.frame: df x x A 1 10 2 20 3 30 从文档中(参见 ?"[" )您可以找到: If drop=TRUE the result is coer
我有一个想要克隆的现有 data.frame,但没有其中的值。 IE。我希望新框架具有与现有框架相同的列名称和类型。原始帧的大小可能为 GB 量级,因此复制和删除数据似乎不是正确的方法,并且迭代现有列
给定两个在列名称/数据类型方面相同的数据帧,其中某些列唯一标识行,是否有一种有效的函数/方法可以让一个数据帧“更新”另一个数据帧? 例如,在下面的例子中,原始和替换由'Name'和'Id'标识>。 g
我是一名优秀的程序员,十分优秀!