text stringlengths 7 35.3M | id stringlengths 11 185 | metadata dict | __index_level_0__ int64 0 2.14k |
|---|---|---|---|
#if UNITY_EDITOR || UNITY_STANDALONE
#define MLA_SUPPORTED_TRAINING_PLATFORM
#endif
#if MLA_SUPPORTED_TRAINING_PLATFORM
using Grpc.Core;
#if UNITY_EDITOR
using UnityEditor;
#endif
using System;
using System.Collections.Generic;
using System.Linq;
using UnityEngine;
using Unity.MLAgents.Actuators;
using Unity.MLAgents.... | ml-agents/com.unity.ml-agents/Runtime/Communicator/RpcCommunicator.cs/0 | {
"file_path": "ml-agents/com.unity.ml-agents/Runtime/Communicator/RpcCommunicator.cs",
"repo_id": "ml-agents",
"token_count": 10978
} | 1,822 |
fileFormatVersion: 2
guid: ebaf7878a8cc74ee3aae07daf9e1b6f2
MonoImporter:
externalObjects: {}
serializedVersion: 2
defaultReferences: []
executionOrder: 0
icon: {instanceID: 0}
userData:
assetBundleName:
assetBundleVariant:
| ml-agents/com.unity.ml-agents/Runtime/Demonstrations/DemonstrationWriter.cs.meta/0 | {
"file_path": "ml-agents/com.unity.ml-agents/Runtime/Demonstrations/DemonstrationWriter.cs.meta",
"repo_id": "ml-agents",
"token_count": 97
} | 1,823 |
fileFormatVersion: 2
guid: a5bca0b650ad3a1b691ab897aead0992
MonoImporter:
externalObjects: {}
serializedVersion: 2
defaultReferences: []
executionOrder: 0
icon: {instanceID: 0}
userData:
assetBundleName:
assetBundleVariant:
| ml-agents/com.unity.ml-agents/Runtime/Grpc/CommunicatorObjects/SpaceType.cs.meta/0 | {
"file_path": "ml-agents/com.unity.ml-agents/Runtime/Grpc/CommunicatorObjects/SpaceType.cs.meta",
"repo_id": "ml-agents",
"token_count": 95
} | 1,824 |
using System;
using System.Collections.Generic;
using System.Linq;
using Unity.Sentis;
using FailedCheck = Unity.MLAgents.Inference.SentisModelParamLoader.FailedCheck;
namespace Unity.MLAgents.Inference
{
/// <summary>
/// Sentis Model extension methods.
/// </summary>
internal static class SentisModel... | ml-agents/com.unity.ml-agents/Runtime/Inference/SentisModelExtensions.cs/0 | {
"file_path": "ml-agents/com.unity.ml-agents/Runtime/Inference/SentisModelExtensions.cs",
"repo_id": "ml-agents",
"token_count": 8475
} | 1,825 |
fileFormatVersion: 2
guid: 7872e22895343467b9fe96d336a7edba
folderAsset: yes
DefaultImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:
| ml-agents/com.unity.ml-agents/Runtime/Inference/Utils.meta/0 | {
"file_path": "ml-agents/com.unity.ml-agents/Runtime/Inference/Utils.meta",
"repo_id": "ml-agents",
"token_count": 68
} | 1,826 |
fileFormatVersion: 2
guid: 795ad5f211e344e5bf3049abd9499721
timeCreated: 1600906663 | ml-agents/com.unity.ml-agents/Runtime/Integrations/Match3/Match3Sensor.cs.meta/0 | {
"file_path": "ml-agents/com.unity.ml-agents/Runtime/Integrations/Match3/Match3Sensor.cs.meta",
"repo_id": "ml-agents",
"token_count": 38
} | 1,827 |
using System.Collections.Generic;
using System;
using System.Collections;
using Unity.MLAgents.Actuators;
using Unity.MLAgents.Sensors;
namespace Unity.MLAgents.Policies
{
/// <summary>
/// The Heuristic Policy uses a hard-coded Heuristic method
/// to take decisions each time the RequestDecision method is... | ml-agents/com.unity.ml-agents/Runtime/Policies/HeuristicPolicy.cs/0 | {
"file_path": "ml-agents/com.unity.ml-agents/Runtime/Policies/HeuristicPolicy.cs",
"repo_id": "ml-agents",
"token_count": 2081
} | 1,828 |
fileFormatVersion: 2
guid: c0c4a98bf1c941b381917cb65209beee
timeCreated: 1611096525 | ml-agents/com.unity.ml-agents/Runtime/Sensors/IBuiltInSensor.cs.meta/0 | {
"file_path": "ml-agents/com.unity.ml-agents/Runtime/Sensors/IBuiltInSensor.cs.meta",
"repo_id": "ml-agents",
"token_count": 41
} | 1,829 |
fileFormatVersion: 2
guid: 6bb6b867a41448888c1cd4f99643ad71
timeCreated: 1573764567 | ml-agents/com.unity.ml-agents/Runtime/Sensors/RayPerceptionSensorComponent3D.cs.meta/0 | {
"file_path": "ml-agents/com.unity.ml-agents/Runtime/Sensors/RayPerceptionSensorComponent3D.cs.meta",
"repo_id": "ml-agents",
"token_count": 39
} | 1,830 |
using System;
using System.Reflection;
namespace Unity.MLAgents.Sensors.Reflection
{
/// <summary>
/// Construction info for a ReflectionSensorBase.
/// </summary>
internal struct ReflectionSensorInfo
{
public object Object;
public FieldInfo FieldInfo;
public PropertyInfo P... | ml-agents/com.unity.ml-agents/Runtime/Sensors/Reflection/ReflectionSensorBase.cs/0 | {
"file_path": "ml-agents/com.unity.ml-agents/Runtime/Sensors/Reflection/ReflectionSensorBase.cs",
"repo_id": "ml-agents",
"token_count": 1362
} | 1,831 |
using System;
using System.Collections.Generic;
using System.Collections.ObjectModel;
using System.Linq;
using UnityEngine;
using Unity.Sentis;
using Unity.MLAgents.Inference;
namespace Unity.MLAgents.Sensors
{
/// <summary>
/// Sensor that wraps around another Sensor to provide temporal stacking.
/// Conc... | ml-agents/com.unity.ml-agents/Runtime/Sensors/StackingSensor.cs/0 | {
"file_path": "ml-agents/com.unity.ml-agents/Runtime/Sensors/StackingSensor.cs",
"repo_id": "ml-agents",
"token_count": 6097
} | 1,832 |
fileFormatVersion: 2
guid: 1a007135a9a1e49849eb2d295f4c3879
MonoImporter:
externalObjects: {}
serializedVersion: 2
defaultReferences: []
executionOrder: 0
icon: {instanceID: 0}
userData:
assetBundleName:
assetBundleVariant:
| ml-agents/com.unity.ml-agents/Runtime/SideChannels/OutgoingMessage.cs.meta/0 | {
"file_path": "ml-agents/com.unity.ml-agents/Runtime/SideChannels/OutgoingMessage.cs.meta",
"repo_id": "ml-agents",
"token_count": 95
} | 1,833 |
fileFormatVersion: 2
guid: f434773fe0f1b41c5b3f446fa0adece4
MonoImporter:
externalObjects: {}
serializedVersion: 2
defaultReferences: []
executionOrder: 0
icon: {instanceID: 0}
userData:
assetBundleName:
assetBundleVariant:
| ml-agents/com.unity.ml-agents/Tests/Editor/AcademyTests.cs.meta/0 | {
"file_path": "ml-agents/com.unity.ml-agents/Tests/Editor/AcademyTests.cs.meta",
"repo_id": "ml-agents",
"token_count": 95
} | 1,834 |
fileFormatVersion: 2
guid: 9f054f620b8b468bbd8ccf7d2cc14ccd
timeCreated: 1607379491 | ml-agents/com.unity.ml-agents/Tests/Editor/Analytics/InferenceAnalyticsTests.cs.meta/0 | {
"file_path": "ml-agents/com.unity.ml-agents/Tests/Editor/Analytics/InferenceAnalyticsTests.cs.meta",
"repo_id": "ml-agents",
"token_count": 42
} | 1,835 |
fileFormatVersion: 2
guid: 4c5a970f5b6be4b57b3bd7a5f84c3623
MonoImporter:
externalObjects: {}
serializedVersion: 2
defaultReferences: []
executionOrder: 0
icon: {instanceID: 0}
userData:
assetBundleName:
assetBundleVariant:
| ml-agents/com.unity.ml-agents/Tests/Editor/DemonstrationTests.cs.meta/0 | {
"file_path": "ml-agents/com.unity.ml-agents/Tests/Editor/DemonstrationTests.cs.meta",
"repo_id": "ml-agents",
"token_count": 99
} | 1,836 |
fileFormatVersion: 2
guid: 7e89e6f6ab7e4c9397958c0320bd5931
timeCreated: 1618359633 | ml-agents/com.unity.ml-agents/Tests/Editor/Integrations.meta/0 | {
"file_path": "ml-agents/com.unity.ml-agents/Tests/Editor/Integrations.meta",
"repo_id": "ml-agents",
"token_count": 43
} | 1,837 |
using NUnit.Framework;
using Unity.MLAgents.Sensors;
namespace Unity.MLAgents.Tests
{
[TestFixture]
public class ObservationSpecTests
{
[Test]
public void TestVectorObsSpec()
{
var obsSpec = ObservationSpec.Vector(5);
Assert.AreEqual(1, obsSpec.Rank);
... | ml-agents/com.unity.ml-agents/Tests/Editor/ObservationSpecTests.cs/0 | {
"file_path": "ml-agents/com.unity.ml-agents/Tests/Editor/ObservationSpecTests.cs",
"repo_id": "ml-agents",
"token_count": 1239
} | 1,838 |
fileFormatVersion: 2
guid: e76819646e3e4424f9c2802edbd2e41b
folderAsset: yes
DefaultImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:
| ml-agents/com.unity.ml-agents/Tests/Editor/Serialization.meta/0 | {
"file_path": "ml-agents/com.unity.ml-agents/Tests/Editor/Serialization.meta",
"repo_id": "ml-agents",
"token_count": 70
} | 1,839 |
fileFormatVersion: 2
guid: 506de2f6a1c74967a6f16ebf494c01d5
timeCreated: 1569370981 | ml-agents/com.unity.ml-agents/Tests/Editor/TimerTest.cs.meta/0 | {
"file_path": "ml-agents/com.unity.ml-agents/Tests/Editor/TimerTest.cs.meta",
"repo_id": "ml-agents",
"token_count": 44
} | 1,840 |
fileFormatVersion: 2
guid: 4c0b188faef38407e82223854fc8eaf5
MonoImporter:
externalObjects: {}
serializedVersion: 2
defaultReferences: []
executionOrder: 0
icon: {instanceID: 0}
userData:
assetBundleName:
assetBundleVariant:
| ml-agents/com.unity.ml-agents/Tests/Runtime/Sensor/CameraSensorComponentTest.cs.meta/0 | {
"file_path": "ml-agents/com.unity.ml-agents/Tests/Runtime/Sensor/CameraSensorComponentTest.cs.meta",
"repo_id": "ml-agents",
"token_count": 94
} | 1,841 |
fileFormatVersion: 2
guid: d2983e2bca9a40398f287727dc0472a5
timeCreated: 1573242741 | ml-agents/com.unity.ml-agents/Tests/Runtime/Sensor/RayPerceptionSensorTests.cs.meta/0 | {
"file_path": "ml-agents/com.unity.ml-agents/Tests/Runtime/Sensor/RayPerceptionSensorTests.cs.meta",
"repo_id": "ml-agents",
"token_count": 41
} | 1,842 |
fileFormatVersion: 2
guid: 917f332e7ad944428f0246683188de8f
timeCreated: 1616137285 | ml-agents/com.unity.ml-agents/Tests/Runtime/Sensor/Unity.ML-Agents.Runtime.Sensor.Tests.asmdef.meta/0 | {
"file_path": "ml-agents/com.unity.ml-agents/Tests/Runtime/Sensor/Unity.ML-Agents.Runtime.Sensor.Tests.asmdef.meta",
"repo_id": "ml-agents",
"token_count": 38
} | 1,843 |
{
"name": "com.unity.ml-agents",
"displayName": "ML Agents",
"version": "3.0.0-exp.1",
"unity": "2023.2",
"description": "Use state-of-the-art machine learning to create intelligent character behaviors in any Unity environment (games, robotics, film, etc.).",
"dependencies": {
"com.unity.sentis": "1.3.0... | ml-agents/com.unity.ml-agents/package.json/0 | {
"file_path": "ml-agents/com.unity.ml-agents/package.json",
"repo_id": "ml-agents",
"token_count": 189
} | 1,844 |
behaviors:
GridWorld:
trainer_type: ppo
hyperparameters:
batch_size: 32
buffer_size: 256
learning_rate: 0.0003
beta: 0.005
epsilon: 0.2
lambd: 0.95
num_epoch: 3
learning_rate_schedule: linear
network_settings:
normalize: false
hidden_units: 128
... | ml-agents/config/ppo/GridWorld.yaml/0 | {
"file_path": "ml-agents/config/ppo/GridWorld.yaml",
"repo_id": "ml-agents",
"token_count": 267
} | 1,845 |
# Custom Side Channels
You can create your own side channel in C# and Python and use it to communicate
custom data structures between the two. This can be useful for situations in
which the data to be sent is too complex or structured for the built-in
`EnvironmentParameters`, or is not related to any specific agent, a... | ml-agents/docs/Custom-SideChannels.md/0 | {
"file_path": "ml-agents/docs/Custom-SideChannels.md",
"repo_id": "ml-agents",
"token_count": 2430
} | 1,846 |
# Limitations
See the package-specific Limitations pages:
- [`com.unity.mlagents` Unity package](https://docs.unity3d.com/Packages/com.unity.ml-agents@2.3/manual/index.html#known-limitations)
- [`mlagents` Python package](../ml-agents/)
- [`mlagents_envs` Python package](../ml-agents-envs/)
| ml-agents/docs/Limitations.md/0 | {
"file_path": "ml-agents/docs/Limitations.md",
"repo_id": "ml-agents",
"token_count": 103
} | 1,847 |
# Unity ML-Agents PettingZoo Wrapper
With the increasing interest in multi-agent training with a gym-like API, we provide a
PettingZoo Wrapper around the [Petting Zoo API](https://pettingzoo.farama.org/). Our wrapper
provides interfaces on top of our `UnityEnvironment` class, which is the default way of
interfacing wi... | ml-agents/docs/Python-PettingZoo-API.md/0 | {
"file_path": "ml-agents/docs/Python-PettingZoo-API.md",
"repo_id": "ml-agents",
"token_count": 870
} | 1,848 |
# Doxyfile 1.8.13
# To generate the C# API documentation, run:
#
# doxygen dox-ml-agents.conf
#
# from the ml-agents-docs directory
#---------------------------------------------------------------------------
# Project related configuration options
#--------------------------------------------------------------------... | ml-agents/docs/dox-ml-agents.conf/0 | {
"file_path": "ml-agents/docs/dox-ml-agents.conf",
"repo_id": "ml-agents",
"token_count": 31323
} | 1,849 |
# 모방학습을 통한 에이전트 학습
에이전트가 시행착오를 통해 스스로 학습하는 것보다 단순히 에이전트가 수행하기를 원하는 행동을 우리가 알려주는 것이 더 직관적일 수 있습니다. 위생병 NPC를 학습하기 위한 [실행 예시](ML-Agents-Overview.md#running-example-training-npc-behaviors) 문서 내용에 대해 생각해보겠습니다. 보상 함수를 이용하여 위생병의 행동을 간접적으로 학습하는 것이 아니라 게임에서 얻어진 관측 (observation)과 게임 컨트롤러를 통해 얻어진 행동들 (actions)의 실제 데이터를 통해 위생병의 행... | ml-agents/localized_docs/KR/docs/Training-Imitation-Learning.md/0 | {
"file_path": "ml-agents/localized_docs/KR/docs/Training-Imitation-Learning.md",
"repo_id": "ml-agents",
"token_count": 6725
} | 1,850 |
"""
Python Environment API for the ML-Agents Toolkit
The aim of this API is to expose Agents evolving in a simulation
to perform reinforcement learning on.
This API supports multi-agent scenarios and groups similar Agents (same
observations, actions spaces and behavior) together. These groups of Agents are
identified b... | ml-agents/ml-agents-envs/mlagents_envs/base_env.py/0 | {
"file_path": "ml-agents/ml-agents-envs/mlagents_envs/base_env.py",
"repo_id": "ml-agents",
"token_count": 8675
} | 1,851 |
# @generated by generate_proto_mypy_stubs.py. Do not edit!
import sys
from google.protobuf.descriptor import (
Descriptor as google___protobuf___descriptor___Descriptor,
)
from google.protobuf.message import (
Message as google___protobuf___message___Message,
)
builtin___bytes = bytes
class CustomResetPar... | ml-agents/ml-agents-envs/mlagents_envs/communicator_objects/custom_reset_parameters_pb2.pyi/0 | {
"file_path": "ml-agents/ml-agents-envs/mlagents_envs/communicator_objects/custom_reset_parameters_pb2.pyi",
"repo_id": "ml-agents",
"token_count": 258
} | 1,852 |
# @generated by generate_proto_mypy_stubs.py. Do not edit!
import sys
from google.protobuf.descriptor import (
Descriptor as google___protobuf___descriptor___Descriptor,
)
from google.protobuf.message import (
Message as google___protobuf___message___Message,
)
from mlagents_envs.communicator_objects.header_... | ml-agents/ml-agents-envs/mlagents_envs/communicator_objects/unity_message_pb2.pyi/0 | {
"file_path": "ml-agents/ml-agents-envs/mlagents_envs/communicator_objects/unity_message_pb2.pyi",
"repo_id": "ml-agents",
"token_count": 985
} | 1,853 |
from mlagents_envs.registry import default_registry
from mlagents_envs.envs.pettingzoo_env_factory import logger, PettingZooEnvFactory
# Register each environment in default_registry as a PettingZooEnv
for key in default_registry:
env_name = key
if key[0].isdigit():
env_name = key.replace("3", "Three")... | ml-agents/ml-agents-envs/mlagents_envs/envs/__init__.py/0 | {
"file_path": "ml-agents/ml-agents-envs/mlagents_envs/envs/__init__.py",
"repo_id": "ml-agents",
"token_count": 231
} | 1,854 |
from mlagents_envs.base_env import (
ActionSpec,
ObservationSpec,
DimensionProperty,
BehaviorSpec,
DecisionSteps,
TerminalSteps,
ObservationType,
)
from mlagents_envs.exception import UnityObservationException
from mlagents_envs.timers import hierarchical_timer, timed
from mlagents_envs.comm... | ml-agents/ml-agents-envs/mlagents_envs/rpc_utils.py/0 | {
"file_path": "ml-agents/ml-agents-envs/mlagents_envs/rpc_utils.py",
"repo_id": "ml-agents",
"token_count": 6988
} | 1,855 |
"""
Copied from ml-agents/mlagents/trainers/tests/simple_test_envs.py
Modified the env so that it doesn't automatically reset and respawn agent in order to pass
pettingzoo api tests, since current PZ api test doesn't allow spawning new agents.
"""
import random
from typing import Dict, List, Any, Tuple
import numpy a... | ml-agents/ml-agents-envs/tests/simple_test_envs.py/0 | {
"file_path": "ml-agents/ml-agents-envs/tests/simple_test_envs.py",
"repo_id": "ml-agents",
"token_count": 9840
} | 1,856 |
import pytest
from mlagents.plugins.stats_writer import register_stats_writer_plugins
from mlagents.trainers.settings import RunOptions
from mlagents_plugin_examples.example_stats_writer import ExampleStatsWriter
@pytest.mark.slow
def test_register_stats_writers():
# Make sure that the ExampleStatsWriter gets r... | ml-agents/ml-agents-plugin-examples/mlagents_plugin_examples/tests/test_stats_writer_plugin.py/0 | {
"file_path": "ml-agents/ml-agents-plugin-examples/mlagents_plugin_examples/tests/test_stats_writer_plugin.py",
"repo_id": "ml-agents",
"token_count": 138
} | 1,857 |
import importlib.metadata as importlib_metadata # pylint: disable=E0611
from typing import Dict, Tuple, Any
from mlagents import plugins as mla_plugins
from mlagents.plugins import ML_AGENTS_TRAINER_TYPE
from mlagents.trainers.poca.optimizer_torch import POCASettings
from mlagents.trainers.poca.trainer import POCATra... | ml-agents/ml-agents/mlagents/plugins/trainer_type.py/0 | {
"file_path": "ml-agents/ml-agents/mlagents/plugins/trainer_type.py",
"repo_id": "ml-agents",
"token_count": 1195
} | 1,858 |
from typing import Any, Dict, List
import numpy as np
from mlagents.torch_utils import torch, default_device
import copy
from mlagents.trainers.action_info import ActionInfo
from mlagents.trainers.behavior_id_utils import get_global_agent_id
from mlagents.trainers.policy import Policy
from mlagents_envs.base_env impor... | ml-agents/ml-agents/mlagents/trainers/policy/torch_policy.py/0 | {
"file_path": "ml-agents/ml-agents/mlagents/trainers/policy/torch_policy.py",
"repo_id": "ml-agents",
"token_count": 2710
} | 1,859 |
{
"metadata": {
"stats_format_version": "0.3.0",
"mlagents_version": "1.1.0.dev0",
"torch_version": "2.1.1+cpu"
}
} | ml-agents/ml-agents/mlagents/trainers/tests/results/ppo/run_logs/training_status.json/0 | {
"file_path": "ml-agents/ml-agents/mlagents/trainers/tests/results/ppo/run_logs/training_status.json",
"repo_id": "ml-agents",
"token_count": 85
} | 1,860 |
from unittest import mock
from unittest.mock import Mock, MagicMock, call, ANY
import unittest
import pytest
from queue import Empty as EmptyQueue
from mlagents.trainers.settings import RunOptions
from mlagents.trainers.subprocess_env_manager import (
SubprocessEnvManager,
EnvironmentResponse,
StepResponse... | ml-agents/ml-agents/mlagents/trainers/tests/test_subprocess_env_manager.py/0 | {
"file_path": "ml-agents/ml-agents/mlagents/trainers/tests/test_subprocess_env_manager.py",
"repo_id": "ml-agents",
"token_count": 5522
} | 1,861 |
import os
from typing import Dict, Any
from unittest.mock import MagicMock
import pytest
import mlagents.trainers.tests.mock_brain as mb
from mlagents.trainers.policy.torch_policy import TorchPolicy
from mlagents.trainers.torch_entities.components.bc.module import BCModule
from mlagents.trainers.torch_entities.networks... | ml-agents/ml-agents/mlagents/trainers/tests/torch_entities/test_bcmodule.py/0 | {
"file_path": "ml-agents/ml-agents/mlagents/trainers/tests/torch_entities/test_bcmodule.py",
"repo_id": "ml-agents",
"token_count": 2286
} | 1,862 |
import numpy as np
from mlagents.trainers.buffer import AgentBuffer, BufferKey
from mlagents_envs.base_env import BehaviorSpec
from mlagents.trainers.trajectory import ObsUtil
def create_agent_buffer(
behavior_spec: BehaviorSpec, number: int, reward: float = 0.0
) -> AgentBuffer:
buffer = AgentBuffer()
cu... | ml-agents/ml-agents/mlagents/trainers/tests/torch_entities/test_reward_providers/utils.py/0 | {
"file_path": "ml-agents/ml-agents/mlagents/trainers/tests/torch_entities/test_reward_providers/utils.py",
"repo_id": "ml-agents",
"token_count": 691
} | 1,863 |
import numpy as np
from typing import Dict, NamedTuple
from mlagents.torch_utils import torch, default_device
from mlagents.trainers.buffer import AgentBuffer, BufferKey
from mlagents.trainers.torch_entities.components.reward_providers.base_reward_provider import (
BaseRewardProvider,
)
from mlagents.trainers.sett... | ml-agents/ml-agents/mlagents/trainers/torch_entities/components/reward_providers/curiosity_reward_provider.py/0 | {
"file_path": "ml-agents/ml-agents/mlagents/trainers/torch_entities/components/reward_providers/curiosity_reward_provider.py",
"repo_id": "ml-agents",
"token_count": 4177
} | 1,864 |
# # Unity ML-Agents Toolkit
from typing import Dict, List, Optional
from collections import defaultdict
import abc
import time
import attr
import numpy as np
from mlagents_envs.side_channel.stats_side_channel import StatsAggregationMethod
from mlagents.trainers.policy.checkpoint_manager import (
ModelCheckpoint,
... | ml-agents/ml-agents/mlagents/trainers/trainer/rl_trainer.py/0 | {
"file_path": "ml-agents/ml-agents/mlagents/trainers/trainer/rl_trainer.py",
"repo_id": "ml-agents",
"token_count": 5451
} | 1,865 |
import sys
import os
SUMMARY_XML_FILENAME = "Summary.xml"
def check_coverage(root_dir, min_percentage):
# Walk the root directory looking for the summary file that
# is output by ther code coverage checks. It's possible that
# we'll need to refine this later in case there are multiple
# such files.
... | ml-agents/ml-agents/tests/yamato/check_coverage_percent.py/0 | {
"file_path": "ml-agents/ml-agents/tests/yamato/check_coverage_percent.py",
"repo_id": "ml-agents",
"token_count": 856
} | 1,866 |
syntax = "proto3";
option csharp_namespace = "Unity.MLAgents.CommunicatorObjects";
package communicator_objects;
/*
* A Capabilities message that will communicate both C# and Python
* what features are available to both.
*/
message UnityRLCapabilitiesProto {
// These are the 1.0 capabilities.
bool baseRLCa... | ml-agents/protobuf-definitions/proto/mlagents_envs/communicator_objects/capabilities.proto/0 | {
"file_path": "ml-agents/protobuf-definitions/proto/mlagents_envs/communicator_objects/capabilities.proto",
"repo_id": "ml-agents",
"token_count": 259
} | 1,867 |
syntax = "proto3";
import "mlagents_envs/communicator_objects/unity_message.proto";
option csharp_namespace = "Unity.MLAgents.CommunicatorObjects";
package communicator_objects;
service UnityToExternalProto {
// Sends the academy parameters
rpc Exchange(UnityMessageProto) returns (UnityMessageProto) {}
}
| ml-agents/protobuf-definitions/proto/mlagents_envs/communicator_objects/unity_to_external.proto/0 | {
"file_path": "ml-agents/protobuf-definitions/proto/mlagents_envs/communicator_objects/unity_to_external.proto",
"repo_id": "ml-agents",
"token_count": 101
} | 1,868 |
using UnityEngine;
using System;
using XLua;
public class LuaMemoryLeakCheckerTest : MonoBehaviour
{
LuaEnv luaenv = new LuaEnv();
Action update;
LuaMemoryLeakChecker.Data data = null;
void Start()
{
luaenv.DoString(@"
local local_leak = {}
global_leak = { a = {}}
... | xLua/General/LuaMemoryLeakChecker/LuaMemoryLeakCheckerTest.cs/0 | {
"file_path": "xLua/General/LuaMemoryLeakChecker/LuaMemoryLeakCheckerTest.cs",
"repo_id": "xLua",
"token_count": 1744
} | 1,869 |
<?xml version="1.0" encoding="utf-8"?>
<Project ToolsVersion="12.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<Import Project="$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props" Condition="Exists('$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft... | xLua/General/vs2013/XLuaGenerate.csproj/0 | {
"file_path": "xLua/General/vs2013/XLuaGenerate.csproj",
"repo_id": "xLua",
"token_count": 1981
} | 1,870 |
fileFormatVersion: 2
guid: 28450407178d7a04fa5767bb74363a1f
timeCreated: 1467600713
licenseType: Pro
MonoImporter:
serializedVersion: 2
defaultReferences: []
executionOrder: 0
icon: {instanceID: 0}
userData:
assetBundleName:
assetBundleVariant:
| xLua/Test/PrefTest/xLuaPerfTest/PerfMain.cs.meta/0 | {
"file_path": "xLua/Test/PrefTest/xLuaPerfTest/PerfMain.cs.meta",
"repo_id": "xLua",
"token_count": 98
} | 1,871 |
fileFormatVersion: 2
guid: 58a8a02fffd75f04196fa18261f6b200
timeCreated: 1483528414
licenseType: Pro
DefaultImporter:
userData:
assetBundleName:
assetBundleVariant:
| xLua/Test/UnitTest/StreamingAssets/luaCallCs.lua.meta/0 | {
"file_path": "xLua/Test/UnitTest/StreamingAssets/luaCallCs.lua.meta",
"repo_id": "xLua",
"token_count": 69
} | 1,872 |
fileFormatVersion: 2
guid: c5ef0d5b807af9e42a0671fcb4b375fa
timeCreated: 1483528418
licenseType: Pro
MonoImporter:
serializedVersion: 2
defaultReferences: []
executionOrder: 0
icon: {instanceID: 0}
userData:
assetBundleName:
assetBundleVariant:
| xLua/Test/UnitTest/xLuaTest/LuaTestObjReflect.cs.meta/0 | {
"file_path": "xLua/Test/UnitTest/xLuaTest/LuaTestObjReflect.cs.meta",
"repo_id": "xLua",
"token_count": 102
} | 1,873 |
.\" $Id: lua.man,v 1.11 2006/01/06 16:03:34 lhf Exp $
.TH LUA 1 "$Date: 2006/01/06 16:03:34 $"
.SH NAME
lua \- Lua interpreter
.SH SYNOPSIS
.B lua
[
.I options
]
[
.I script
[
.I args
]
]
.SH DESCRIPTION
.B lua
is the stand-alone Lua interpreter.
It loads and executes Lua programs,
either in textual source form or
in p... | xLua/build/lua-5.1.5/doc/lua.1/0 | {
"file_path": "xLua/build/lua-5.1.5/doc/lua.1",
"repo_id": "xLua",
"token_count": 1095
} | 1,874 |
/*
* The code below can be used to make a Lua core that does not contain the
* parsing modules (lcode, llex, lparser), which represent 35% of the total core.
* You'll only be able to load binary files and strings, precompiled with luac.
* (Of course, you'll have to build luac with the original parsing modules!)
*
* To ... | xLua/build/lua-5.1.5/etc/noparser.c/0 | {
"file_path": "xLua/build/lua-5.1.5/etc/noparser.c",
"repo_id": "xLua",
"token_count": 476
} | 1,875 |
/*
** $Id: lfunc.c,v 2.12.1.2 2007/12/28 14:58:43 roberto Exp $
** Auxiliary functions to manipulate prototypes and closures
** See Copyright Notice in lua.h
*/
#include <stddef.h>
#define lfunc_c
#define LUA_CORE
#include "lua.h"
#include "lfunc.h"
#include "lgc.h"
#include "lmem.h"
#include "lobject.h"
#include ... | xLua/build/lua-5.1.5/src/lfunc.c/0 | {
"file_path": "xLua/build/lua-5.1.5/src/lfunc.c",
"repo_id": "xLua",
"token_count": 2195
} | 1,876 |
/*
** $Id: lopcodes.h,v 1.125.1.1 2007/12/27 13:02:25 roberto Exp $
** Opcodes for Lua virtual machine
** See Copyright Notice in lua.h
*/
#ifndef lopcodes_h
#define lopcodes_h
#include "llimits.h"
/*===========================================================================
We assume that instructions are unsign... | xLua/build/lua-5.1.5/src/lopcodes.h/0 | {
"file_path": "xLua/build/lua-5.1.5/src/lopcodes.h",
"repo_id": "xLua",
"token_count": 3840
} | 1,877 |
/*
** $Id: luac.c,v 1.54 2006/06/02 17:37:11 lhf Exp $
** Lua compiler (saves bytecodes to files; also list bytecodes)
** See Copyright Notice in lua.h
*/
#include <errno.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#define luac_c
#define LUA_CORE
#include "lua.h"
#include "lauxlib.h"
#include "ldo... | xLua/build/lua-5.1.5/src/luac.c/0 | {
"file_path": "xLua/build/lua-5.1.5/src/luac.c",
"repo_id": "xLua",
"token_count": 2084
} | 1,878 |
# LuaDist CMake utility library for Lua.
#
# Copyright (C) 2007-2012 LuaDist.
# by David Manura, Peter Drahos
# Redistribution and use of this file is allowed according to the terms of the MIT license.
# For details see the COPYRIGHT file distributed with LuaDist.
# Please note that the package source code is licensed... | xLua/build/lua-5.3.3/cmake/lua.cmake/0 | {
"file_path": "xLua/build/lua-5.3.3/cmake/lua.cmake",
"repo_id": "xLua",
"token_count": 5495
} | 1,879 |
#include <windows.h>
#include <stdlib.h> /* declaration of __argc and __argv */
extern int main(int, char **);
int PASCAL WinMain(HINSTANCE hinst, HINSTANCE hprev, LPSTR cmdline, int ncmdshow)
{
int rc;
extern int __argc; /* this seems to work for all the compilers we tested, except Watcom compilers */
e... | xLua/build/lua-5.3.3/src/wmain.c/0 | {
"file_path": "xLua/build/lua-5.3.3/src/wmain.c",
"repo_id": "xLua",
"token_count": 150
} | 1,880 |
/*
** $Id: ldo.h $
** Stack and Call structure of Lua
** See Copyright Notice in lua.h
*/
#ifndef ldo_h
#define ldo_h
#include "lobject.h"
#include "lstate.h"
#include "lzio.h"
/*
** Macro to check stack size and grow stack if needed. Parameters
** 'pre'/'pos' allow the macro to preserve a pointer into the
** sta... | xLua/build/lua-5.4.1/src/ldo.h/0 | {
"file_path": "xLua/build/lua-5.4.1/src/ldo.h",
"repo_id": "xLua",
"token_count": 1189
} | 1,881 |
/*
** $Id: lobject.c $
** Some generic functions over Lua objects
** See Copyright Notice in lua.h
*/
#define lobject_c
#define LUA_CORE
#include "lprefix.h"
#include <locale.h>
#include <math.h>
#include <stdarg.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include "lua.h"
#include "lctype.h"
#i... | xLua/build/lua-5.4.1/src/lobject.c/0 | {
"file_path": "xLua/build/lua-5.4.1/src/lobject.c",
"repo_id": "xLua",
"token_count": 8345
} | 1,882 |
/* This is a generated file. DO NOT EDIT! */
static const int libbc_endian = 0;
static const uint8_t libbc_code[] = {
#if LJ_FR2
0,1,2,0,0,1,2,24,1,0,0,76,1,2,0,241,135,158,166,3,220,203,178,130,4,0,1,2,0,
0,1,2,24,1,0,0,76,1,2,0,243,244,148,165,20,198,190,199,252,3,0,1,2,0,0,0,3,
16,0,5,0,21,1,0,0,76,1,2,0,0,2,10,0,... | xLua/build/luajit-2.1.0b2/src/host/buildvm_libbc.h/0 | {
"file_path": "xLua/build/luajit-2.1.0b2/src/host/buildvm_libbc.h",
"repo_id": "xLua",
"token_count": 1593
} | 1,883 |
/*
** Buffer handling.
** Copyright (C) 2005-2016 Mike Pall. See Copyright Notice in luajit.h
*/
#ifndef _LJ_BUF_H
#define _LJ_BUF_H
#include "lj_obj.h"
#include "lj_gc.h"
#include "lj_str.h"
/* Resizable string buffers. Struct definition in lj_obj.h. */
#define sbufB(sb) (mref((sb)->b, char))
#define sbufP(sb) (mre... | xLua/build/luajit-2.1.0b2/src/lj_buf.h/0 | {
"file_path": "xLua/build/luajit-2.1.0b2/src/lj_buf.h",
"repo_id": "xLua",
"token_count": 1465
} | 1,884 |
<!DOCTYPE html>
<html>
<head>
<title>String Buffer Library</title>
<meta charset="utf-8">
<meta name="Copyright" content="Copyright (C) 2005-2021">
<meta name="Language" content="en">
<link rel="stylesheet" type="text/css" href="bluequad.css" media="screen">
<link rel="stylesheet" type="text/css" href="bluequad-print.c... | xLua/build/luajit-2.1.0b3/doc/ext_buffer.html/0 | {
"file_path": "xLua/build/luajit-2.1.0b3/doc/ext_buffer.html",
"repo_id": "xLua",
"token_count": 8108
} | 1,885 |
#include <assert.h>
#include <stdio.h>
#include <sys/mman.h>
#include "../dasm_proto.h"
#include "../dasm_s390x.h"
// DynASM directives.
|.arch s390x
|.actionlist actions
|.globals lab_
static void add(dasm_State *state)
{
dasm_State ** Dst = &state;
| ar r2,r3
| br r14
}
/*
static void add_rrd(dasm_State *s... | xLua/build/luajit-2.1.0b3/dynasm/Examples/test_z_inst.c/0 | {
"file_path": "xLua/build/luajit-2.1.0b3/dynasm/Examples/test_z_inst.c",
"repo_id": "xLua",
"token_count": 4988
} | 1,886 |
/*
** Internal assertions.
** Copyright (C) 2005-2021 Mike Pall. See Copyright Notice in luajit.h
*/
#define lj_assert_c
#define LUA_CORE
#if defined(LUA_USE_ASSERT) || defined(LUA_USE_APICHECK)
#include <stdio.h>
#include "lj_obj.h"
void lj_assert_fail(global_State *g, const char *file, int line,
const char... | xLua/build/luajit-2.1.0b3/src/lj_assert.c/0 | {
"file_path": "xLua/build/luajit-2.1.0b3/src/lj_assert.c",
"repo_id": "xLua",
"token_count": 262
} | 1,887 |
/*
** Trace recorder (bytecode -> SSA IR).
** Copyright (C) 2005-2021 Mike Pall. See Copyright Notice in luajit.h
*/
#define lj_record_c
#define LUA_CORE
#include "lj_obj.h"
#if LJ_HASJIT
#include "lj_err.h"
#include "lj_str.h"
#include "lj_tab.h"
#include "lj_meta.h"
#include "lj_frame.h"
#if LJ_HASFFI
#include "l... | xLua/build/luajit-2.1.0b3/src/lj_record.c/0 | {
"file_path": "xLua/build/luajit-2.1.0b3/src/lj_record.c",
"repo_id": "xLua",
"token_count": 44404
} | 1,888 |
/*
** Table handling.
** Copyright (C) 2005-2021 Mike Pall. See Copyright Notice in luajit.h
*/
#ifndef _LJ_TAB_H
#define _LJ_TAB_H
#include "lj_obj.h"
/* Hash constants. Tuned using a brute force search. */
#define HASH_BIAS (-0x04c11db7)
#define HASH_ROT1 14
#define HASH_ROT2 5
#define HASH_ROT3 13
/* Scramble th... | xLua/build/luajit-2.1.0b3/src/lj_tab.h/0 | {
"file_path": "xLua/build/luajit-2.1.0b3/src/lj_tab.h",
"repo_id": "xLua",
"token_count": 1620
} | 1,889 |
/*
** Math helper functions for assembler VM.
** Copyright (C) 2005-2021 Mike Pall. See Copyright Notice in luajit.h
*/
#define lj_vmmath_c
#define LUA_CORE
#include <errno.h>
#include <math.h>
#include "lj_obj.h"
#include "lj_ir.h"
#include "lj_vm.h"
/* -- Wrapper functions ----------------------------------------... | xLua/build/luajit-2.1.0b3/src/lj_vmmath.c/0 | {
"file_path": "xLua/build/luajit-2.1.0b3/src/lj_vmmath.c",
"repo_id": "xLua",
"token_count": 1748
} | 1,890 |
#!/bin/sh
DIR=$(cd $(dirname $0); pwd)
cd $DIR
LUAJIT=$DIR/../../luajit
HASERR=0
find $DIR/unit -name "*.lua" -print | while read x; do
$LUAJIT $x >/dev/null 2>/dev/null
if [ $? -eq 0 ]; then
echo "$x ok"
else
HASERR=1
echo "$x failed"
fi
done
if [ $HASERR -eq 0 ]; then
ex... | xLua/build/luajit-2.1.0b3/src/x64/test/unit_test.sh/0 | {
"file_path": "xLua/build/luajit-2.1.0b3/src/x64/test/unit_test.sh",
"repo_id": "xLua",
"token_count": 177
} | 1,891 |
/* luasocket_scripts.h.h */
#ifndef __LUA_MODULES_606BA1C00D116CA81B695C141D124DB7_H_
#define __LUA_MODULES_606BA1C00D116CA81B695C141D124DB7_H_
#if __cplusplus
extern "C" {
#endif
#include "lua.h"
void luaopen_luasocket_scripts(lua_State* L);
/*
int luaopen_lua_m_ltn12(lua_State* L);
int luaopen_lua_m_mime(lua_St... | xLua/build/luasocket/luasocket_scripts.h/0 | {
"file_path": "xLua/build/luasocket/luasocket_scripts.h",
"repo_id": "xLua",
"token_count": 377
} | 1,892 |
#ifndef UNIX_H
#define UNIX_H
/*=========================================================================*\
* Unix domain object
* LuaSocket toolkit
*
* This module is just an example of how to extend LuaSocket with a new
* domain.
\*=========================================================================*/
#include ... | xLua/build/luasocket/unix.h/0 | {
"file_path": "xLua/build/luasocket/unix.h",
"repo_id": "xLua",
"token_count": 222
} | 1,893 |
cd luajit-2.1.0b3
make clean
make CFLAGS=-fPIC
cd ..
mkdir -p build_linux64_lj && cd build_linux64_lj
cmake -DUSING_LUAJIT=ON ../
cd ..
cmake --build build_linux64_lj --config Release
mkdir -p plugin_luajit/Plugins/x86_64/
cp build_linux64_lj/libxlua.so plugin_luajit/Plugins/x86_64/libxlua.so
| xLua/build/make_linux64_luajit.sh/0 | {
"file_path": "xLua/build/make_linux64_luajit.sh",
"repo_id": "xLua",
"token_count": 136
} | 1,894 |
mkdir build64_54 & pushd build64_54
cmake -DLUA_VERSION=5.4.1 -G "Visual Studio 16 2019" -A x64 ..
popd
cmake --build build64_54 --config Release
md plugin_lua54\Plugins\x86_64
copy /Y build64_54\Release\xlua.dll plugin_lua54\Plugins\x86_64\xlua.dll
mkdir build32_54 & pushd build32_54
cmake -DLUA_VERSION=5.4.1 -G "Vi... | xLua/build/make_win_lua54.bat/0 | {
"file_path": "xLua/build/make_win_lua54.bat",
"repo_id": "xLua",
"token_count": 204
} | 1,895 |
---
title: 可以使用的markdown
type: detail
order: 0
---
## 主标题
title 为标题
type 固定为guide宝宝埋的坑
order 为左侧导航排序,但是注意,假设0开始是基础的区域,100后是教程的区域,如果你想把文章放到基础区域,那么order必须小于100
> 这是小提示框用法

ps:markdown的图片不会调整大小所以如果要使用调整大小的图片应该用:
<img width="173" height="57"... | xLua/docs/source/src/readme.md/0 | {
"file_path": "xLua/docs/source/src/readme.md",
"repo_id": "xLua",
"token_count": 783
} | 1,896 |
<% var isIndex = page.path === 'index.html' %>
<!DOCTYPE html>
<html lang="en">
<head>
<title><%- page.title ? page.title + ' — ' : '' %>XLua</title>
<meta charset="utf-8">
<meta name="description" content="<%- theme.site_description %>">
<meta name="viewport" content="width=device-width, initial-s... | xLua/docs/source/themes/catlib/layout/layout.ejs/0 | {
"file_path": "xLua/docs/source/themes/catlib/layout/layout.ejs",
"repo_id": "xLua",
"token_count": 344
} | 1,897 |
#!/usr/bin/env bash
SCRIPT_PATH="$(cd "$(dirname "$0")"; pwd -P)"
g++ \
-Wfatal-errors \
-c $SCRIPT_PATH/src/main.cxx \
-o $SCRIPT_PATH/3d-game-shaders-for-beginners.o \
-std=gnu++11 \
-O3 \
-I/usr/include/python3.9/ \
-I$P3D_INCLUDE_PATH
g++ \
$SCRIPT_PATH/3d-game-shaders-for-beginners.o \
-o $SCR... | 3d-game-shaders-for-beginners/demonstration/build-for-linux.sh/0 | {
"file_path": "3d-game-shaders-for-beginners/demonstration/build-for-linux.sh",
"repo_id": "3d-game-shaders-for-beginners",
"token_count": 255
} | 0 |
/*
(C) 2020 David Lettier
lettier.com
*/
#version 150
uniform sampler2D p3d_Texture1;
uniform vec2 normalMapsEnabled;
in vec4 vertexPosition;
in vec3 vertexNormal;
in vec3 binormal;
in vec3 tangent;
in vec2 normalCoord;
out vec4 positionOut;
out vec4 normalOut;
void main() {
vec4 normalTex =
texture
... | 3d-game-shaders-for-beginners/demonstration/shaders/fragment/geometry-buffer-0.frag/0 | {
"file_path": "3d-game-shaders-for-beginners/demonstration/shaders/fragment/geometry-buffer-0.frag",
"repo_id": "3d-game-shaders-for-beginners",
"token_count": 379
} | 1 |
/*
(C) 2019 David Lettier
lettier.com
*/
#version 150
uniform vec2 pi;
uniform vec2 gamma;
uniform sampler2D uvTexture;
uniform sampler2D maskTexture;
uniform sampler2D positionFromTexture;
uniform sampler2D positionToTexture;
uniform sampler2D backgroundColorTexture;
uniform vec2 sunPosition;
out vec4 fragCol... | 3d-game-shaders-for-beginners/demonstration/shaders/fragment/refraction.frag/0 | {
"file_path": "3d-game-shaders-for-beginners/demonstration/shaders/fragment/refraction.frag",
"repo_id": "3d-game-shaders-for-beginners",
"token_count": 554
} | 2 |
<!DOCTYPE html>
<html xmlns="http://www.w3.org/1999/xhtml" lang="" xml:lang="">
<head>
<meta charset="utf-8" />
<meta name="viewport" content="width=device-width, initial-scale=1.0, user-scalable=yes" />
<meta name="description" content="Interested in adding textures, lighting, shadows, normal maps, glowi... | 3d-game-shaders-for-beginners/docs/bloom.html/0 | {
"file_path": "3d-game-shaders-for-beginners/docs/bloom.html",
"repo_id": "3d-game-shaders-for-beginners",
"token_count": 5231
} | 3 |
<!DOCTYPE html>
<html xmlns="http://www.w3.org/1999/xhtml" lang="" xml:lang="">
<head>
<meta charset="utf-8" />
<meta name="viewport" content="width=device-width, initial-scale=1.0, user-scalable=yes" />
<meta name="description" content="Interested in adding textures, lighting, shadows, normal maps, glowi... | 3d-game-shaders-for-beginners/docs/index.html/0 | {
"file_path": "3d-game-shaders-for-beginners/docs/index.html",
"repo_id": "3d-game-shaders-for-beginners",
"token_count": 1891
} | 4 |
<!DOCTYPE html>
<html xmlns="http://www.w3.org/1999/xhtml" lang="" xml:lang="">
<head>
<meta charset="utf-8" />
<meta name="viewport" content="width=device-width, initial-scale=1.0, user-scalable=yes" />
<meta name="description" content="Interested in adding textures, lighting, shadows, normal maps, glowi... | 3d-game-shaders-for-beginners/docs/ssao.html/0 | {
"file_path": "3d-game-shaders-for-beginners/docs/ssao.html",
"repo_id": "3d-game-shaders-for-beginners",
"token_count": 14984
} | 5 |
[:arrow_backward:](blinn-phong.md)
[:arrow_double_up:](../README.md)
[:arrow_up_small:](#)
[:arrow_down_small:](#copyright)
[:arrow_forward:](rim-lighting.md)
# 3D Game Shaders For Beginners
## Fresnel Factor
<p align="center">
<img src="https://i.imgur.com/3lQL51m.gif" alt="Fresnel" title="Fresnel">
</p>
The fresn... | 3d-game-shaders-for-beginners/sections/fresnel-factor.md/0 | {
"file_path": "3d-game-shaders-for-beginners/sections/fresnel-factor.md",
"repo_id": "3d-game-shaders-for-beginners",
"token_count": 1633
} | 6 |
[:arrow_backward:](gamma-correction.md)
[:arrow_double_up:](../README.md)
[:arrow_up_small:](#)
[:arrow_down_small:](#copyright)
[:arrow_forward:](building-the-demo.md)
# 3D Game Shaders For Beginners
## Setup
<p align="center">
<img src="https://i.imgur.com/fYpIWNk.gif" alt="Setup" title="Setup">
</p>
Below is the... | 3d-game-shaders-for-beginners/sections/setup.md/0 | {
"file_path": "3d-game-shaders-for-beginners/sections/setup.md",
"repo_id": "3d-game-shaders-for-beginners",
"token_count": 1365
} | 7 |
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License.
#ifndef air_ApiProvider_hpp
#define air_ApiProvider_hpp
#include "VehicleApiBase.hpp"
#include "VehicleSimApiBase.hpp"
#include "WorldSimApiBase.hpp"
#include <map>
#include "common/common_utils/UniqueValueMap.hpp"
namesp... | AirSim/AirLib/include/api/ApiProvider.hpp/0 | {
"file_path": "AirSim/AirLib/include/api/ApiProvider.hpp",
"repo_id": "AirSim",
"token_count": 1182
} | 8 |
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License.
#ifndef air_Earth_hpp
#define air_Earth_hpp
#include <cmath>
#include <exception>
#include "common/CommonStructs.hpp"
#include "common/Common.hpp"
namespace msr
{
namespace airlib
{
class EarthUtils
{
private... | AirSim/AirLib/include/common/EarthUtils.hpp/0 | {
"file_path": "AirSim/AirLib/include/common/EarthUtils.hpp",
"repo_id": "AirSim",
"token_count": 10380
} | 9 |
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License.
#ifndef air_Waiter_hpp
#define air_Waiter_hpp
#include <chrono>
#include <iostream>
#include "common/Common.hpp"
#include "common/common_utils/Utils.hpp"
#include "common/ClockFactory.hpp"
#include "common/CancelToken.hpp"... | AirSim/AirLib/include/common/Waiter.hpp/0 | {
"file_path": "AirSim/AirLib/include/common/Waiter.hpp",
"repo_id": "AirSim",
"token_count": 993
} | 10 |
#ifndef CommonUtils_Timer_hpp
#define CommonUtils_Timer_hpp
#include <chrono>
#include "Utils.hpp"
namespace common_utils
{
class Timer
{
public:
Timer()
{
started_ = false;
}
void start()
{
started_ = true;
start_ = now();
}
void stop()
{
started_ = fals... | AirSim/AirLib/include/common/common_utils/Timer.hpp/0 | {
"file_path": "AirSim/AirLib/include/common/common_utils/Timer.hpp",
"repo_id": "AirSim",
"token_count": 547
} | 11 |
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License.
#ifndef airsim_core_Kinematics_hpp
#define airsim_core_Kinematics_hpp
#include "common/Common.hpp"
#include "common/UpdatableObject.hpp"
#include "common/CommonStructs.hpp"
namespace msr
{
namespace airlib
{
class Ki... | AirSim/AirLib/include/physics/Kinematics.hpp/0 | {
"file_path": "AirSim/AirLib/include/physics/Kinematics.hpp",
"repo_id": "AirSim",
"token_count": 1380
} | 12 |
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License.
#ifndef msr_airlib_BarometerSimpleParams_hpp
#define msr_airlib_BarometerSimpleParams_hpp
#include "common/Common.hpp"
#include "common/AirSimSettings.hpp"
namespace msr
{
namespace airlib
{
struct BarometerSimplePar... | AirSim/AirLib/include/sensors/barometer/BarometerSimpleParams.hpp/0 | {
"file_path": "AirSim/AirLib/include/sensors/barometer/BarometerSimpleParams.hpp",
"repo_id": "AirSim",
"token_count": 1128
} | 13 |
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License.
#ifndef msr_airlib_vehicles_CarApiFactory_hpp
#define msr_airlib_vehicles_CarApiFactory_hpp
#include "vehicles/car/firmwares/physxcar/PhysXCarApi.hpp"
#include "vehicles/car/firmwares/ardurover/ArduRoverApi.hpp"
namespace... | AirSim/AirLib/include/vehicles/car/CarApiFactory.hpp/0 | {
"file_path": "AirSim/AirLib/include/vehicles/car/CarApiFactory.hpp",
"repo_id": "AirSim",
"token_count": 706
} | 14 |
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License.
#ifndef air_MultirotorRpcLibServer_hpp
#define air_MultirotorRpcLibServer_hpp
#include "common/Common.hpp"
#include <functional>
#include "api/RpcLibServerBase.hpp"
#include "vehicles/multirotor/api/MultirotorApiBase.hpp"
... | AirSim/AirLib/include/vehicles/multirotor/api/MultirotorRpcLibServer.hpp/0 | {
"file_path": "AirSim/AirLib/include/vehicles/multirotor/api/MultirotorRpcLibServer.hpp",
"repo_id": "AirSim",
"token_count": 327
} | 15 |
#pragma once
#include <string>
#include <exception>
#include "interfaces/IController.hpp"
#include "interfaces/IStateEstimator.hpp"
#include "interfaces/ICommLink.hpp"
#include "interfaces/IGoal.hpp"
#include "AngleRateController.hpp"
#include "AngleLevelController.hpp"
#include "PassthroughController.hpp"
#include "C... | AirSim/AirLib/include/vehicles/multirotor/firmwares/simple_flight/firmware/CascadeController.hpp/0 | {
"file_path": "AirSim/AirLib/include/vehicles/multirotor/firmwares/simple_flight/firmware/CascadeController.hpp",
"repo_id": "AirSim",
"token_count": 2401
} | 16 |
#pragma once
#include <cstdint>
namespace simple_flight
{
class IBoardClock
{
public:
virtual uint64_t micros() const = 0;
virtual uint64_t millis() const = 0;
virtual ~IBoardClock() = default;
};
}
| AirSim/AirLib/include/vehicles/multirotor/firmwares/simple_flight/firmware/interfaces/IBoardClock.hpp/0 | {
"file_path": "AirSim/AirLib/include/vehicles/multirotor/firmwares/simple_flight/firmware/interfaces/IBoardClock.hpp",
"repo_id": "AirSim",
"token_count": 84
} | 17 |
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License.
//in header only mode, control library is not available
#ifndef AIRLIB_HEADER_ONLY
#include "safety/SafetyEval.hpp"
#include "vehicles/multirotor/api/MultirotorCommon.hpp"
#include <cmath>
#include <sstream>
namespace ms... | AirSim/AirLib/src/safety/SafetyEval.cpp/0 | {
"file_path": "AirSim/AirLib/src/safety/SafetyEval.cpp",
"repo_id": "AirSim",
"token_count": 4851
} | 18 |
#ifndef msr_AirLibUnitTests_WorkerThreadThreadTest_hpp
#define msr_AirLibUnitTests_WorkerThreadThreadTest_hpp
#include "common/WorkerThread.hpp"
#include "common/common_utils/Timer.hpp"
#include <chrono>
#include "TestBase.hpp"
namespace msr
{
namespace airlib
{
class WorkerThreadTest : public TestBase
{
... | AirSim/AirLibUnitTests/WorkerThreadTest.hpp/0 | {
"file_path": "AirSim/AirLibUnitTests/WorkerThreadTest.hpp",
"repo_id": "AirSim",
"token_count": 2057
} | 19 |
{
"SeeDocsAt": "https://github.com/Microsoft/AirSim/blob/main/docs/settings.md",
"SettingsVersion": 1.2,
"SimMode": "ComputerVision",
"CameraDefaults": {
"CaptureSettings": [
{
"ImageType": 0,
"TargetGamma": 1.5,
"Width": 960,
"Height": 540,
"FOV_Degrees": 90
},
{
... | AirSim/Examples/DataCollection/DataCollectorSGM_settings.json/0 | {
"file_path": "AirSim/Examples/DataCollection/DataCollectorSGM_settings.json",
"repo_id": "AirSim",
"token_count": 553
} | 20 |
#pragma once
#include "sensors/imu/ImuSimple.hpp"
#include "sensors/Barometer/BarometerSimple.hpp"
#include "sensors/Magnetometer/MagnetometerSimple.hpp"
#include "common/Common.hpp"
#include <thread>
#include <ostream>
namespace msr
{
namespace airlib
{
class StandALoneSensors
{
public:
static vo... | AirSim/Examples/StandAloneSensors.hpp/0 | {
"file_path": "AirSim/Examples/StandAloneSensors.hpp",
"repo_id": "AirSim",
"token_count": 5332
} | 21 |
<Application x:Class="LogViewer.App"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:local="clr-namespace:LogViewer"
StartupUri="MainWindow.xaml">
<Application.Resources>
<Reso... | AirSim/LogViewer/LogViewer/App.xaml/0 | {
"file_path": "AirSim/LogViewer/LogViewer/App.xaml",
"repo_id": "AirSim",
"token_count": 264
} | 22 |
using LogViewer.Utilities;
using Microsoft.Networking.Mavlink;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Data;
using System.Windows.Documents;
using System.Windows.Input;
... | AirSim/LogViewer/LogViewer/Controls/Console.xaml.cs/0 | {
"file_path": "AirSim/LogViewer/LogViewer/Controls/Console.xaml.cs",
"repo_id": "AirSim",
"token_count": 5272
} | 23 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.