instance_id stringlengths 10 57 | file_changes listlengths 1 15 | repo stringlengths 7 53 | base_commit stringlengths 40 40 | problem_statement stringlengths 11 52.5k | patch stringlengths 251 7.06M |
|---|---|---|---|---|---|
UC-Davis-molecular-computing__scadnano-python-package-284 | [
{
"changes": {
"added_entities": [
"scadnano/scadnano.py:ModificationType.key"
],
"added_modules": null,
"edited_entities": [
"scadnano/scadnano.py:Strand.set_modification_5p",
"scadnano/scadnano.py:Strand.set_modification_3p",
"scadnano/scadnano.py:Strand... | UC-Davis-molecular-computing/scadnano-python-package | fc3086264e1e5857f7585b2e382d4330cee60822 | deal with non-unique Modification vendor codes
Eurofins does not use unique vendor codes for their modifications:
https://eurofinsgenomics.com/en/products/dnarna-synthesis/mods/
For example, Biotin TEG can be used on the 5' or 3' end, but both use the code `[BIOTEG]`.
Deal with this somehow, now that scadnano ... | diff --git a/scadnano/scadnano.py b/scadnano/scadnano.py
index 8cec304..fbd93bd 100644
--- a/scadnano/scadnano.py
+++ b/scadnano/scadnano.py
@@ -858,7 +858,10 @@ strands_key = 'strands'
scaffold_key = 'scaffold'
helices_view_order_key = 'helices_view_order'
is_origami_key = 'is_origami'
-design_modifications_key = '... |
UC-Davis-molecular-computing__scadnano-python-package-288 | [
{
"changes": {
"added_entities": [
"scadnano/scadnano.py:_vendor_dna_sequence_substrand",
"scadnano/scadnano.py:Loopout.vendor_dna_sequence",
"scadnano/scadnano.py:Extension.strand",
"scadnano/scadnano.py:Extension.vendor_dna_sequence"
],
"added_modules": [
... | UC-Davis-molecular-computing/scadnano-python-package | f415a4773feb665d556dbb709eba67058f8e6ea1 | export DNA sequences from extensions and loopouts
This code crashes:
```python
design = sc.Design(helices=[sc.Helix(max_offset=100)])
design.draw_strand(0, 0).extension_5p(3).move(5).with_sequence('TTT' + 'AAAAA')
contents = design.to_idt_bulk_input_format()
```
with this exception:
```
..\scadnano\scadna... | diff --git a/scadnano/scadnano.py b/scadnano/scadnano.py
index 9b4e869..e0902ee 100644
--- a/scadnano/scadnano.py
+++ b/scadnano/scadnano.py
@@ -54,7 +54,7 @@ so the user must take care not to set them.
# needed to use forward annotations: https://docs.python.org/3/whatsnew/3.7.html#whatsnew37-pep563
from __future__ ... |
UCSBarchlab__PyRTL-297 | [
{
"changes": {
"added_entities": [
"pyrtl/memory.py:_reset_memory_indexer"
],
"added_modules": [
"pyrtl/memory.py:_reset_memory_indexer"
],
"edited_entities": null,
"edited_modules": null
},
"file": "pyrtl/memory.py"
},
{
"changes": {
"ad... | UCSBarchlab/PyRTL | 28fb6aa71600769b58bedc1176657ea0abd19153 | Missing OutputToVerilog text test
Just noticed there isn't a test for the actual text produced by the Verilog output class. Right now it's a `pass`. Seems like there should be a comprehensive test since there have been a number of issues related to small Verilog output bugs.
| diff --git a/pyrtl/memory.py b/pyrtl/memory.py
index b9ed0f9..1df9416 100644
--- a/pyrtl/memory.py
+++ b/pyrtl/memory.py
@@ -33,6 +33,11 @@ _MemAssignment = collections.namedtuple('_MemAssignment', 'rhs, is_conditional')
"""_MemAssignment is the type returned from assignment by |= or <<="""
+def _reset_memory_inde... |
UCSBarchlab__PyRTL-365 | [
{
"changes": {
"added_entities": null,
"added_modules": null,
"edited_entities": [
"pyrtl/visualization.py:output_to_graphviz",
"pyrtl/visualization.py:block_to_graphviz_string",
"pyrtl/visualization.py:block_to_svg"
],
"edited_modules": [
"pyrtl/vis... | UCSBarchlab/PyRTL | 79099f53f44ce56a3864d31ce002bc2a60e0b441 | Improve visualization of nets where order of incoming edges matters
For nets where the order of incoming edges matters (e.g. `c`, `-`, `<`, `>`, `x`, and `@`), it would be nice to improve the way visualizations present them.
For example, given the following netlist:
```
tmp6/1W <-- s -- i/8I ((4,))
tmp4/1W <-- s ... | diff --git a/pyrtl/visualization.py b/pyrtl/visualization.py
index 3514091..ab9bc33 100644
--- a/pyrtl/visualization.py
+++ b/pyrtl/visualization.py
@@ -6,8 +6,9 @@ The functions provided write the block as a given visual format to the file.
"""
from __future__ import print_function, unicode_literals
+import collec... |
UCSBarchlab__PyRTL-462 | [
{
"changes": {
"added_entities": null,
"added_modules": null,
"edited_entities": null,
"edited_modules": null
},
"file": "pyrtl/__init__.py"
},
{
"changes": {
"added_entities": [
"pyrtl/helperfuncs.py:binary_to_one_hot"
],
"added_modules": [
... | UCSBarchlab/PyRTL | 5077c2474b58a320f1a475c8c91a8904dcaefd26 | Optimize is currently missing the elimination of "double not"
The pyrtl.optimize code is not eliminating "double not" conditions (reducing them to a single wire). Right now it does some more complex optimizations including CSE but this very simple case gets missed. You can see very clearly from the code below.
```... | diff --git a/.gitignore b/.gitignore
index 75c349e..1a33fac 100644
--- a/.gitignore
+++ b/.gitignore
@@ -51,3 +51,6 @@ ipynb-examples/.ipynb_checkpoints
# VS Code
.vscode
+
+# Python venv
+pyvenv.cfg
\ No newline at end of file
diff --git a/codecov.yml b/codecov.yml
index 17dfa01..7aae220 100644
--- a/codecov.yml
+... |
UCSBarchlab__PyRTL-466 | [
{
"changes": {
"added_entities": null,
"added_modules": null,
"edited_entities": null,
"edited_modules": null
},
"file": "pyrtl/__init__.py"
},
{
"changes": {
"added_entities": [
"pyrtl/helperfuncs.py:binary_to_one_hot"
],
"added_modules": [
... | UCSBarchlab/PyRTL | e25b20c8f0e84eba3290eae26fa46be5e0b661e4 | Add a helper function to encode binary to 1-hot
Takes an input representing a bit position and returns a WireVector with that bit position set to 1 and the others to 0. | diff --git a/docs/helpers.rst b/docs/helpers.rst
index 1dba231..894a2dc 100644
--- a/docs/helpers.rst
+++ b/docs/helpers.rst
@@ -111,4 +111,5 @@ Encoders and Decoders
---------------------
.. autofunction:: pyrtl.helperfuncs.one_hot_to_binary
+.. autofunction:: pyrtl.helperfuncs.binary_to_one_hot
diff --git a/pyr... |
UKPLab__sentence-transformers-2918 | [
{
"changes": {
"added_entities": null,
"added_modules": null,
"edited_entities": [
"sentence_transformers/SentenceTransformer.py:SentenceTransformer.__init__"
],
"edited_modules": [
"sentence_transformers/SentenceTransformer.py:SentenceTransformer"
]
},
... | UKPLab/sentence-transformers | ef360c82f447fa31b6ff1f58c526151f772ff984 | Cannot restart training of model that necessitates `trust_remote_code=True` flag
## What is the issue
If your training is interrupted and you want to restart it with flag `resume_from_checkpoint`, the `Trainer` tries to reload the model via the `_load_from_checkpoint` method. However, this method does not take as in... | diff --git a/sentence_transformers/SentenceTransformer.py b/sentence_transformers/SentenceTransformer.py
index 2bb55df..cb1a952 100644
--- a/sentence_transformers/SentenceTransformer.py
+++ b/sentence_transformers/SentenceTransformer.py
@@ -167,6 +167,7 @@ class SentenceTransformer(nn.Sequential, FitMixin):
se... |
UKPLab__sentence-transformers-3178 | [
{
"changes": {
"added_entities": null,
"added_modules": null,
"edited_entities": null,
"edited_modules": [
"sentence_transformers/training_args.py:SentenceTransformerTrainingArguments"
]
},
"file": "sentence_transformers/training_args.py"
}
] | UKPLab/sentence-transformers | b2a50617c7967863d4f42493a09280e5733990ad | Parse arguments with HfArgumentParser
I was using HfArgumentParser to parse `SentenceTransformerTrainingArguments` and met the following error:
```
parser = HfArgumentParser(SentenceTransformerTrainingArguments)`
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "/home/admin/.local/... | diff --git a/sentence_transformers/training_args.py b/sentence_transformers/training_args.py
index 68a659e..da9a65d 100644
--- a/sentence_transformers/training_args.py
+++ b/sentence_transformers/training_args.py
@@ -2,6 +2,7 @@ from __future__ import annotations
import logging
from dataclasses import dataclass, fi... |
USEPA__WNTR-272 | [
{
"changes": {
"added_entities": null,
"added_modules": null,
"edited_entities": [
"wntr/network/elements.py:Pattern.__init__"
],
"edited_modules": [
"wntr/network/elements.py:Pattern"
]
},
"file": "wntr/network/elements.py"
}
] | USEPA/WNTR | 4647acdf9a78b63cdfe4044786ca90f1c85175b0 | pattern to json error if type is int32
Dear all,
i noticed that an exception is thrown if a pattern is part of the network which consists only of integers should be written to json.
A minimal example :
wn = wntr.network.WaterNetworkModel()
wn.add_pattern('pat0', [0,1,0,1,0,1,0])
wn.write_json(f'temp.json')
... | diff --git a/wntr/network/elements.py b/wntr/network/elements.py
index 1d18be0e..0a05a964 100644
--- a/wntr/network/elements.py
+++ b/wntr/network/elements.py
@@ -1964,7 +1964,7 @@ class Pattern(object):
self.name = name
if isinstance(multipliers, (int, float)):
multipliers = [multipliers... |
UXARRAY__uxarray-1003 | [
{
"changes": {
"added_entities": null,
"added_modules": null,
"edited_entities": [
"uxarray/core/dataarray.py:UxDataArray._slice_from_grid"
],
"edited_modules": [
"uxarray/core/dataarray.py:UxDataArray"
]
},
"file": "uxarray/core/dataarray.py"
},
{... | UXARRAY/uxarray | 6061d2e5d303aa69d70e564e4df169d2479b301b | `_slice_from_grid` may need to use coords from a sliced dataarray
### Version
v2024.08.2
### How did you install UXarray?
Conda
### What happened?
`_slice_from_grid` in UxDataArray create a new subset dataarray using coordinates info from the original dataarray as shown in the lines below:
https://github.com/UXAR... | diff --git a/docs/user-guide/subset.ipynb b/docs/user-guide/subset.ipynb
index e220a880..07df1e82 100644
--- a/docs/user-guide/subset.ipynb
+++ b/docs/user-guide/subset.ipynb
@@ -16,10 +16,6 @@
"cell_type": "code",
"execution_count": null,
"metadata": {
- "ExecuteTime": {
- "end_time": "2024-06-07T22... |
UXARRAY__uxarray-1011 | [
{
"changes": {
"added_entities": null,
"added_modules": null,
"edited_entities": [
"uxarray/cross_sections/dataarray_accessor.py:UxDataArrayCrossSectionAccessor.constant_longitude"
],
"edited_modules": [
"uxarray/cross_sections/dataarray_accessor.py:UxDataArrayCross... | UXARRAY/uxarray | 948b0f50cb0ddb708623d65293bdcddf60722de7 | Constant Longitude Cross Sections
Compute the cross section at a line of constant longitude | diff --git a/docs/user-guide/cross-sections.ipynb b/docs/user-guide/cross-sections.ipynb
index 9c0ba703..ab408b8b 100644
--- a/docs/user-guide/cross-sections.ipynb
+++ b/docs/user-guide/cross-sections.ipynb
@@ -16,8 +16,10 @@
"id": "b35ba4a2c30750e4",
"metadata": {
"ExecuteTime": {
- "end_time": "2024-... |
UXARRAY__uxarray-1072 | [
{
"changes": {
"added_entities": null,
"added_modules": null,
"edited_entities": null,
"edited_modules": null
},
"file": "uxarray/__init__.py"
},
{
"changes": {
"added_entities": null,
"added_modules": null,
"edited_entities": [
"uxarray/cross_se... | UXARRAY/uxarray | 282b69732827a04c94496366079772baebad31c5 | Performance Issue: Unnecessary Re-conversion of Coordinates in `point_within_gca`
### Proposed new feature or change:
The current implementation of point_within_gca unnecessarily re-converts lat/lon coordinates from Cartesian coordinates, which negatively impacts performance.
The following lines re-compute lat/lon ... | diff --git a/docs/api.rst b/docs/api.rst
index 1b03b5d3..f9146e69 100644
--- a/docs/api.rst
+++ b/docs/api.rst
@@ -126,6 +126,8 @@ Descriptors
Grid.descriptors
Grid.face_areas
Grid.bounds
+ Grid.face_bounds_lon
+ Grid.face_bounds_lat
Grid.edge_node_distances
Grid.edge_face_distances
Grid.ant... |
UXARRAY__uxarray-1158 | [
{
"changes": {
"added_entities": null,
"added_modules": null,
"edited_entities": [
"uxarray/cross_sections/dataarray_accessor.py:UxDataArrayCrossSectionAccessor.gca",
"uxarray/cross_sections/dataarray_accessor.py:UxDataArrayCrossSectionAccessor.gca_gca"
],
"edited_m... | UXARRAY/uxarray | cd3558aa0f6606cf75b897af94381578c1d86e77 | Improve Test Coverage for `uxarray.subset` | diff --git a/uxarray/cross_sections/dataarray_accessor.py b/uxarray/cross_sections/dataarray_accessor.py
index 43365b79..7d7610db 100644
--- a/uxarray/cross_sections/dataarray_accessor.py
+++ b/uxarray/cross_sections/dataarray_accessor.py
@@ -133,9 +133,6 @@ class UxDataArrayCrossSectionAccessor:
lats : Tuple[... |
UXARRAY__uxarray-263 | [
{
"changes": {
"added_entities": [
"uxarray/grid.py:Grid._build_edge_node_connectivity"
],
"added_modules": null,
"edited_entities": [
"uxarray/grid.py:Grid.__init__",
"uxarray/grid.py:Grid._populate_cartesian_xyz_coord",
"uxarray/grid.py:Grid._populate_lo... | UXARRAY/uxarray | 84dd54d471d76afac126d15c8e0f65f8460e75b8 | Add `Grid._build_edge_node_connectivity`
Add a function for constructing the connectivity variable `Mesh2_edge_nodes` as described in the UGRID conventions for a Flexible 2D Mesh Topology | diff --git a/docs/internal_api/index.rst b/docs/internal_api/index.rst
index 734a59ff..4d585842 100644
--- a/docs/internal_api/index.rst
+++ b/docs/internal_api/index.rst
@@ -19,6 +19,7 @@ Grid Methods
grid.Grid.__from_ds__
grid.Grid.__from_vert__
grid.Grid.__init_grid_var_attrs__
+ grid.Grid._build_edge_... |
UXARRAY__uxarray-308 | [
{
"changes": {
"added_entities": [
"uxarray/grid.py:Grid._build_nNodes_per_face"
],
"added_modules": null,
"edited_entities": [
"uxarray/grid.py:Grid.__init__",
"uxarray/grid.py:Grid.compute_face_areas",
"uxarray/grid.py:Grid._build_face_dimension"
]... | UXARRAY/uxarray | 03194ce953e9ed96bb3636a22506ea5a109395ab | Rename `face_dimension` connectivity to `nNodes_per_face`
Current implementation of `face_dimension` does not align with the UGRID conventions. `nNodes_per_face` is a more appropriate name for the current implementation of `face_dimension` | diff --git a/docs/internal_api/index.rst b/docs/internal_api/index.rst
index b6f2a237..68251aef 100644
--- a/docs/internal_api/index.rst
+++ b/docs/internal_api/index.rst
@@ -23,7 +23,7 @@ Grid Methods
grid.Grid._build_face_edges_connectivity
grid.Grid._populate_cartesian_xyz_coord
grid.Grid._populate_lonla... |
UXARRAY__uxarray-325 | [
{
"changes": {
"added_entities": [
"uxarray/core/grid.py:Grid.__repr__",
"uxarray/core/grid.py:Grid.parsed_attrs",
"uxarray/core/grid.py:Grid.Mesh2",
"uxarray/core/grid.py:Grid.nMesh2_node",
"uxarray/core/grid.py:Grid.nMesh2_face",
"uxarray/core/grid.py:Grid... | UXARRAY/uxarray | f16dbf18d89fbae70cfb5f81e0f471be04ef7d0b | Grid Topology Representation between Dataset, DataArray, and Grid
We are storing all grid variables through an internal dataset (`uxgrid._ds`) and access attributes (`uxgrid.Mesh2_node_x`) under our `uxgrid` accessor.
This works fine for the `Grid` class, however access to this dataset is not clear for the Dataset ... | diff --git a/docs/internal_api/index.rst b/docs/internal_api/index.rst
index 5c47cd5a..a20cd385 100644
--- a/docs/internal_api/index.rst
+++ b/docs/internal_api/index.rst
@@ -18,7 +18,6 @@ Grid Methods
__init_grid_var_names__
__from_ds__
__from_vert__
- __init_grid_var_attrs__
_build_edge_node_connect... |
UXARRAY__uxarray-331 | [
{
"changes": {
"added_entities": null,
"added_modules": null,
"edited_entities": [
"uxarray/_mpas.py:_dual_to_ugrid"
],
"edited_modules": [
"uxarray/_mpas.py:_dual_to_ugrid"
]
},
"file": "uxarray/_mpas.py"
}
] | UXARRAY/uxarray | df5308f15cee91aab7b54657cd65d39a9b105b81 | Represent MPAS dual mesh as a mixed topology grid
When we are converting a MPAS Dual Mesh into the UGRID conventions, we represent the face nodes as a Triangular Mesh Topology instead of Flexible Mesh Topology, similar to how is done for the Primal Mesh. For consistency across the package, we'd like all grids to be a ... | diff --git a/uxarray/_mpas.py b/uxarray/_mpas.py
index 4652dd2b..ebc33c6c 100644
--- a/uxarray/_mpas.py
+++ b/uxarray/_mpas.py
@@ -196,9 +196,10 @@ def _dual_to_ugrid(in_ds, out_ds):
out_ds["Mesh2_face_nodes"] = xr.DataArray(
data=cellsOnVertex,
- dims=["nMesh2_face", "Three"],
+ dims=["nM... |
UXARRAY__uxarray-390 | [
{
"changes": {
"added_entities": null,
"added_modules": null,
"edited_entities": [
"uxarray/core/api.py:open_dataset",
"uxarray/core/api.py:open_mfdataset"
],
"edited_modules": [
"uxarray/core/api.py:open_dataset",
"uxarray/core/api.py:open_mfdataset... | UXARRAY/uxarray | 22e2ec8a852962b567057adcc2196dcd6c230d0c | Add additional `**kwargs` for opening a grid file with `ux.open_dataset`
Related to #385 & #384
Using `ux.open_dataset` with a separate grid and data file does not allow for passing in arguments in the subsequent `xr.open_dataset` call that happens in `ux.open_grid`, restricting the user (see #385)
Add the abili... | diff --git a/uxarray/core/api.py b/uxarray/core/api.py
index 6a73f632..e4f09656 100644
--- a/uxarray/core/api.py
+++ b/uxarray/core/api.py
@@ -106,6 +106,7 @@ def open_dataset(grid_filename_or_obj: str,
islatlon: Optional[bool] = False,
isconcave: Optional[bool] = False,
... |
UXARRAY__uxarray-877 | [
{
"changes": {
"added_entities": [
"uxarray/__init__.py:enable_fma",
"uxarray/__init__.py:disable_fma"
],
"added_modules": [
"uxarray/__init__.py:enable_fma",
"uxarray/__init__.py:disable_fma"
],
"edited_entities": null,
"edited_modules": null
... | UXARRAY/uxarray | 1790e0e30abf6b8869c35747d6393af03bccac88 | Optimize Face Bounds Construction
### Proposed new feature or change:
Optimize the performance when constructing `Grid.face_bounds` | diff --git a/benchmarks/face_bounds.py b/benchmarks/face_bounds.py
index c41602b6..b249e7b9 100644
--- a/benchmarks/face_bounds.py
+++ b/benchmarks/face_bounds.py
@@ -10,8 +10,6 @@ grid_geoflow = current_path / "test" / "meshfiles" / "ugrid" / "geoflow-small" /
grid_scrip = current_path / "test" / "meshfiles" / "scrip... |
UXARRAY__uxarray-878 | [
{
"changes": {
"added_entities": [
"benchmarks/mpas_ocean.py:CheckNorm.setup",
"benchmarks/mpas_ocean.py:CheckNorm.teardown",
"benchmarks/mpas_ocean.py:CheckNorm.time_check_norm"
],
"added_modules": [
"benchmarks/mpas_ocean.py:CheckNorm"
],
"edited_e... | UXARRAY/uxarray | f159bb1cba224ef5035bddb6c3b24b2487940f70 | Inconsistent Normalization of Cartesian Coordinates in `node_x`, `node_y`, and `node_z`
### Version
v2024.06
### How did you install UXarray?
Conda
### What happened?
Our project performs geometric operations on unstructured grids on a unit sphere, which means all points on the sphere should be normalized. The no... | diff --git a/benchmarks/mpas_ocean.py b/benchmarks/mpas_ocean.py
index b4d50da4..f10fa691 100644
--- a/benchmarks/mpas_ocean.py
+++ b/benchmarks/mpas_ocean.py
@@ -140,7 +140,20 @@ class RemapUpsample:
def time_inverse_distance_weighted_remapping(self):
self.uxds_480["bottomDepth"].remap.inverse_distance_w... |
UXARRAY__uxarray-899 | [
{
"changes": {
"added_entities": [
"benchmarks/mpas_ocean.py:HoleEdgeIndices.setup",
"benchmarks/mpas_ocean.py:HoleEdgeIndices.teardown",
"benchmarks/mpas_ocean.py:HoleEdgeIndices.time_construct_hole_edge_indices"
],
"added_modules": [
"benchmarks/mpas_ocean.py:... | UXARRAY/uxarray | f71e11bef0fabe3ac74767767ad0509cef5cf504 | Function to Check For Meshes With Holes
### Proposed new feature or change:
Function that returns whether or not a mesh has holes in it. Something like this:
`Grid.contains_holes()`
Returns True if any holes exists and False if not. | diff --git a/benchmarks/mpas_ocean.py b/benchmarks/mpas_ocean.py
index d2baaf86..51b0c99d 100644
--- a/benchmarks/mpas_ocean.py
+++ b/benchmarks/mpas_ocean.py
@@ -164,3 +164,17 @@ class RemapUpsample:
def time_inverse_distance_weighted_remapping(self):
self.uxds_480["bottomDepth"].remap.inverse_distance... |
UXARRAY__uxarray-915 | [
{
"changes": {
"added_entities": null,
"added_modules": null,
"edited_entities": [
"uxarray/core/api.py:open_dataset",
"uxarray/core/api.py:open_mfdataset"
],
"edited_modules": [
"uxarray/core/api.py:open_dataset",
"uxarray/core/api.py:open_mfdataset... | UXARRAY/uxarray | 82e46b8c79bb0107753398ddab096c5f6eb9b718 | Support Dask Arrays for Grid
Currently, the `Grid` class is entirely written around NumPy arrays. We should support Dask arrays. | diff --git a/docs/user_api/index.rst b/docs/user_api/index.rst
index ac521c04..ec3278b6 100644
--- a/docs/user_api/index.rst
+++ b/docs/user_api/index.rst
@@ -224,6 +224,7 @@ Methods
Grid.get_kd_tree
Grid.copy
Grid.isel
+ Grid.chunk
Dimensions
diff --git a/uxarray/core/api.py b/uxarray/core/api.py
in... |
UXARRAY__uxarray-953 | [
{
"changes": {
"added_entities": [
"uxarray/io/_mpas.py:_parse_face_areas"
],
"added_modules": [
"uxarray/io/_mpas.py:_parse_face_areas"
],
"edited_entities": [
"uxarray/io/_mpas.py:_primal_to_ugrid",
"uxarray/io/_mpas.py:_dual_to_ugrid"
],
... | UXARRAY/uxarray | a6265968ec0fdce5518302185f3d8b6d75b45dab | Parse Face Areas from MPAS Grids
Most MPAS grid datasets already contain face areas, parse them at the I/O step. | diff --git a/uxarray/io/_mpas.py b/uxarray/io/_mpas.py
index af155967..d9f83142 100644
--- a/uxarray/io/_mpas.py
+++ b/uxarray/io/_mpas.py
@@ -59,6 +59,9 @@ def _primal_to_ugrid(in_ds, out_ds):
if "cellsOnCell" in in_ds:
_parse_face_faces(in_ds, out_ds)
+ if "areaCell" in in_ds:
+ _parse_face_... |
Uberi__speech_recognition-619 | [
{
"changes": {
"added_entities": null,
"added_modules": null,
"edited_entities": [
"speech_recognition/__init__.py:Recognizer.recognize_google"
],
"edited_modules": [
"speech_recognition/__init__.py:Recognizer"
]
},
"file": "speech_recognition/__init__... | Uberi/speech_recognition | 45c0a25d48561a1deccc0632fb949d8533bbd34e | unittest is failing due to change for recognize_google method to return tuples with confidence
Steps to reproduce
------------------
1. `git clone` this repository
2. `python3.9 -m venv venv --upgrade-deps`, then `source venv/bin/activate`
3. `pip install -e .`
4. `pip install pocketsphinx`
5. `python -m unitte... | diff --git a/speech_recognition/__init__.py b/speech_recognition/__init__.py
index 39d042a..ed86b75 100644
--- a/speech_recognition/__init__.py
+++ b/speech_recognition/__init__.py
@@ -855,7 +855,7 @@ class Recognizer(AudioSource):
if hypothesis is not None: return hypothesis.hypstr
raise UnknownValue... |
Unidata__MetPy-1908 | [
{
"changes": {
"added_entities": null,
"added_modules": null,
"edited_entities": [
"src/metpy/io/metar.py:parse_metar_to_dataframe"
],
"edited_modules": [
"src/metpy/io/metar.py:parse_metar_to_dataframe"
]
},
"file": "src/metpy/io/metar.py"
},
{
... | Unidata/MetPy | 70cd77768ff68edb5a2b6bd1a07ec87ca5a8ad0d | METAR Parser Documentation Improvement
The notes section for the METAR parser could be improved in getting a better listing of the parameters that come out of the parser.
https://unidata.github.io/MetPy/latest/api/generated/metpy.io.parse_metar_file.html
Currently, the documentation comes out in one continuous pa... | diff --git a/docs/api/references.rst b/docs/api/references.rst
index 3021de45c7..e990023d55 100644
--- a/docs/api/references.rst
+++ b/docs/api/references.rst
@@ -192,5 +192,9 @@ References
.. [WMO8] WMO, 2018: Guide to Meteorological Instruments and Methods of Observation.
`WMO No.8 <https://library.wmo.i... |
Unidata__MetPy-1928 | [
{
"changes": {
"added_entities": null,
"added_modules": null,
"edited_entities": [
"src/metpy/calc/indices.py:precipitable_water"
],
"edited_modules": [
"src/metpy/calc/indices.py:precipitable_water"
]
},
"file": "src/metpy/calc/indices.py"
},
{
... | Unidata/MetPy | d3f8a83d59e03b7120b84dd18def8d3915fd3a70 | `Level3File` import is a bit bloated
I am using the Level3File class to process some radar data on a server. I do not use any other features from MetPy. I have two issues with the import proess:
1. Upon importing Level3File, I always receive an error `Cannot import USCOUNTIES and USSTATES without Cartopy installed.`... | diff --git a/.github/workflows/nightly-builds.yml b/.github/workflows/nightly-builds.yml
index d799cacf54..099599fc33 100644
--- a/.github/workflows/nightly-builds.yml
+++ b/.github/workflows/nightly-builds.yml
@@ -53,7 +53,7 @@ jobs:
run: |
cat ci/extra_requirements.txt >> ci/test_requirements.txt
... |
Unidata__MetPy-1934 | [
{
"changes": {
"added_entities": null,
"added_modules": null,
"edited_entities": [
"src/metpy/io/metar_parser.py:TreeNode.__init__",
"src/metpy/io/metar_parser.py:TreeNode8.__init__",
"src/metpy/io/metar_parser.py:TreeNode9.__init__",
"src/metpy/io/metar_parser.... | Unidata/MetPy | be68bb508212ff08565ddf64e2efbaa157965127 | Clean up CodeQL config
Right now it's still scanning the generated `metpy_parser.py` for some reason, which is generating a ton of issues we aren't going to fix.
Not sure why, we seem to be setting things correctly [according to the docs](https://docs.github.com/en/code-security/secure-coding/configuring-code-scanni... | diff --git a/.codeclimate.yml b/.codeclimate.yml
index 0cb746cd60..680d017144 100644
--- a/.codeclimate.yml
+++ b/.codeclimate.yml
@@ -40,8 +40,7 @@ plugins:
exclude_patterns:
- "src/metpy/io/_nexrad_msgs/msg*.py"
-- "src/metpy/io/metar_parse.peg"
-- "src/metpy/io/metar_parser.py"
+- "src/metpy/io/_metar_parser/*"
... |
Unidata__MetPy-1943 | [
{
"changes": {
"added_entities": null,
"added_modules": null,
"edited_entities": [
"src/metpy/calc/tools.py:_get_bound_pressure_height"
],
"edited_modules": [
"src/metpy/calc/tools.py:_get_bound_pressure_height"
]
},
"file": "src/metpy/calc/tools.py"
... | Unidata/MetPy | 7da06af4e756df6fef4f0aefe504ac94680d9882 | get_layer heights unit issue
Using `get_layer` on some sounding data works oddly when asking for data in height. A request for data from 1-5km and 1000-5000m do not return the same data!
```python
import metpy.calc as mpcalc
from datetime import datetime
from metpy.units import units, pandas_dataframe_to_unit_arr... | diff --git a/src/metpy/calc/tools.py b/src/metpy/calc/tools.py
index 73d1de8863..91727ea35b 100644
--- a/src/metpy/calc/tools.py
+++ b/src/metpy/calc/tools.py
@@ -388,9 +388,8 @@ def _get_bound_pressure_height(pressure, bound, height=None, interpolate=True):
# Need to cast back to the input type si... |
Unidata__MetPy-1956 | [
{
"changes": {
"added_entities": null,
"added_modules": null,
"edited_entities": [
"src/metpy/calc/cross_sections.py:absolute_momentum"
],
"edited_modules": [
"src/metpy/calc/cross_sections.py:absolute_momentum"
]
},
"file": "src/metpy/calc/cross_secti... | Unidata/MetPy | ec278cd2fca2664d54343bf213e7f3de7a77666c | Error in absolute_momentum (bug in normal_component?)
I want to get absolute momentum with xarray.DataArray like:
```
ds = xr.DataArray(...) # set data, including 'u' and 'v'
cross = cross_section(data, ...) # create cross section
m = absolute_momentum(cross['u'], cross['v'])
```
But DimensionalityError occur... | diff --git a/ci/doc_requirements.txt b/ci/doc_requirements.txt
index 0e9bdc51bd..9c1a752596 100644
--- a/ci/doc_requirements.txt
+++ b/ci/doc_requirements.txt
@@ -1,4 +1,4 @@
-sphinx==4.0.3
+sphinx==4.0.2
# Jinja 3 breaks until we bump pydata-sphinx-theme (I think)
jinja2<3
pydata-sphinx-theme==0.5.2
diff --git a/ci... |
Unidata__MetPy-1977 | [
{
"changes": {
"added_entities": null,
"added_modules": null,
"edited_entities": [
"src/metpy/calc/tools.py:azimuth_range_to_lat_lon"
],
"edited_modules": [
"src/metpy/calc/tools.py:azimuth_range_to_lat_lon"
]
},
"file": "src/metpy/calc/tools.py"
}
] | Unidata/MetPy | beeed8b6db334a79fcb28fc5490be5c6f80a85c7 | Fix unit-handling in azimuth_range_to_lat_lon
`azimuth_range_to_lat_lon` currently says:
https://github.com/Unidata/MetPy/blob/3173ec65de269ed2bcf9d6ef7c2ee79c27c31c13/src/metpy/calc/tools.py#L856-L867
This is problematic because:
1. Contrary to the docs, we don't actually handle non-degrees
2. We suggest `meters... | diff --git a/src/metpy/calc/tools.py b/src/metpy/calc/tools.py
index d2544a6af7..19e5fac426 100644
--- a/src/metpy/calc/tools.py
+++ b/src/metpy/calc/tools.py
@@ -4,6 +4,7 @@
"""Contains a collection of generally useful calculation tools."""
import functools
from operator import itemgetter
+import warnings
import... |
Unidata__MetPy-2006 | [
{
"changes": {
"added_entities": null,
"added_modules": null,
"edited_entities": [
"src/metpy/calc/tools.py:reduce_point_density"
],
"edited_modules": [
"src/metpy/calc/tools.py:reduce_point_density"
]
},
"file": "src/metpy/calc/tools.py"
}
] | Unidata/MetPy | c74b47141fa02df4a414c7ff5b98eefe6b69620d | reduce_point_density and bad points
Make `reduce_point_density` handle points (e.g. nans and infinities) by automatically setting their mask to `False`. These points can result from the lat/lon location not being valid in the projected space. | diff --git a/src/metpy/calc/tools.py b/src/metpy/calc/tools.py
index 19e5fac426..3e7c0d53fc 100644
--- a/src/metpy/calc/tools.py
+++ b/src/metpy/calc/tools.py
@@ -248,6 +248,9 @@ def reduce_point_density(points, radius, priority=None):
stations with higher precipitation remain in the mask). The points and radius c... |
Unidata__MetPy-2007 | [
{
"changes": {
"added_entities": null,
"added_modules": null,
"edited_entities": [
"src/metpy/calc/thermo.py:showalter_index"
],
"edited_modules": [
"src/metpy/calc/thermo.py:showalter_index"
]
},
"file": "src/metpy/calc/thermo.py"
}
] | Unidata/MetPy | c74b47141fa02df4a414c7ff5b98eefe6b69620d | Showalter Index calculation difference from value in Wyoming upperair website
I use showalter_index function from MetPy/src/metpy/calc/thermo.py and compare result with value that show in Wyoming upperair website. I found it difference, How can I solve this problem?
SI from showalter_index = 11.34
SI in Wyoming up... | diff --git a/src/metpy/calc/thermo.py b/src/metpy/calc/thermo.py
index e570b0cada..f847196e7d 100644
--- a/src/metpy/calc/thermo.py
+++ b/src/metpy/calc/thermo.py
@@ -3314,27 +3314,26 @@ def gradient_richardson_number(height, potential_temperature, u, v, vertical_dim
@exporter.export
@preprocess_and_wrap()
@check_un... |
Unidata__MetPy-2066 | [
{
"changes": {
"added_entities": null,
"added_modules": null,
"edited_entities": [
"src/metpy/io/gempak.py:GempakGrid.gdxarray"
],
"edited_modules": [
"src/metpy/io/gempak.py:GempakGrid"
]
},
"file": "src/metpy/io/gempak.py"
}
] | Unidata/MetPy | da3bf7d4c9c3a4a11b0c74eaebadf32ec78accfc | GEMPAK reader assigns grid mapping information incorrectly
As referenced in https://github.com/Unidata/MetPy/issues/641, the GEMPAK reader (particularly https://github.com/Unidata/MetPy/blob/e263d08e71ac55d2d9f12fa6c11594f4c3bea74d/src/metpy/io/gempak.py#L1266-L1280) incorrectly inserts the CF grid mapping attributes a... | diff --git a/setup.cfg b/setup.cfg
index 60c803d1bf..a229f9604b 100644
--- a/setup.cfg
+++ b/setup.cfg
@@ -46,7 +46,7 @@ install_requires =
pandas>=0.24.0
pint>=0.10.1
pooch>=0.1
- pyproj>=2.3.0
+ pyproj>=2.5.0
scipy>=1.2.0
traitlets>=4.3.0
xarray>=0.14.1
diff --git a/src/metpy/io/ge... |
Unidata__MetPy-2073 | [
{
"changes": {
"added_entities": null,
"added_modules": null,
"edited_entities": null,
"edited_modules": null
},
"file": "src/metpy/calc/thermo.py"
},
{
"changes": {
"added_entities": null,
"added_modules": null,
"edited_entities": [
"src/metpy/x... | Unidata/MetPy | 5ab290b30b2ca88fd655089395dd61186c2c1883 | Problems with xarray broadcasting/dimensions
I've encountered pretty easily some challenges trying to use XArray-based data, specifically when pulling out 1D pressure coordinates to use as a data field. I was able to easily fix `heat_index` by adding `broadcast` to the `preprocess_and_wrap` decorator, but I haven't qui... | diff --git a/src/metpy/calc/thermo.py b/src/metpy/calc/thermo.py
index 35053e8ef6..94b9aaac4b 100644
--- a/src/metpy/calc/thermo.py
+++ b/src/metpy/calc/thermo.py
@@ -3053,7 +3053,7 @@ def static_stability(pressure, temperature, vertical_dim=0):
@exporter.export
@preprocess_and_wrap(
wrap_like='temperature',
- ... |
Unidata__MetPy-2239 | [
{
"changes": {
"added_entities": null,
"added_modules": null,
"edited_entities": [
"src/metpy/calc/thermo.py:moist_lapse"
],
"edited_modules": [
"src/metpy/calc/thermo.py:moist_lapse"
]
},
"file": "src/metpy/calc/thermo.py"
}
] | Unidata/MetPy | 84d0110c4bf509b0535959117baf8dc9e4000927 | moist_lapse fails for increasing pressure arrays whose first element is the reference pressure
I'm using Mac, Python 3.8.5 and MetPy 1.1.0, and the following code
```python
import metpy.calc as mpcalc
from metpy.units import units
mpcalc.moist_lapse([600, 700]*units.mbar, 0*units.celsius)
```
produces a `ValueE... | diff --git a/src/metpy/calc/thermo.py b/src/metpy/calc/thermo.py
index c433f63a3b..bbc7a34e84 100644
--- a/src/metpy/calc/thermo.py
+++ b/src/metpy/calc/thermo.py
@@ -316,16 +316,12 @@ def moist_lapse(pressure, temperature, reference_pressure=None):
org_units = temperature.units
temperature = np.atleast_1d(te... |
Unidata__MetPy-2270 | [
{
"changes": {
"added_entities": null,
"added_modules": null,
"edited_entities": [
"src/metpy/io/_metar_parser/metar_parser.py:Grammar._read_cover"
],
"edited_modules": [
"src/metpy/io/_metar_parser/metar_parser.py:Grammar"
]
},
"file": "src/metpy/io/_... | Unidata/MetPy | ac602b28e24da3a44d9c34230dfb48d1499053f0 | parse_metar fails when vertical visibility report is truncated
### What went wrong?
When a METAR vertical visibility group (VV) reports ceiling below station level (///) but the number of slashes is less than 3, parse_metar() returns: ValueError: invalid literal for int() with base 10: ''
In the example below, rep... | diff --git a/ci/doc_requirements.txt b/ci/doc_requirements.txt
index 97749bc88c..6a8a691e28 100644
--- a/ci/doc_requirements.txt
+++ b/ci/doc_requirements.txt
@@ -1,4 +1,4 @@
-sphinx==4.3.2
+sphinx==4.3.1
pydata-sphinx-theme==0.7.2
sphinx-gallery==0.10.1
myst-parser==0.16.1
diff --git a/ci/requirements.txt b/ci/requ... |
Unidata__MetPy-2271 | [
{
"changes": {
"added_entities": null,
"added_modules": null,
"edited_entities": [
"src/metpy/interpolate/points.py:natural_neighbor_to_points",
"src/metpy/interpolate/points.py:inverse_distance_to_points",
"src/metpy/interpolate/points.py:interpolate_to_points"
]... | Unidata/MetPy | 4f1e6bb18d0a16a421292dfbd21d03ed983a7952 | Support units in `inverse_distance_to_points`
Currently `inverse_distance_to_points` chokes when given `values` having units because it does:
https://github.com/Unidata/MetPy/blob/749cf07ec2d15e644f822e45796bd5b20dc3dd7c/src/metpy/interpolate/points.py#L257-L258
This means when calling `interpolate_to_grid` using... | diff --git a/src/metpy/interpolate/points.py b/src/metpy/interpolate/points.py
index aab9f9c5d7..a68c7d4b7b 100644
--- a/src/metpy/interpolate/points.py
+++ b/src/metpy/interpolate/points.py
@@ -3,6 +3,7 @@
# SPDX-License-Identifier: BSD-3-Clause
"""Interpolate data valid at one set of points to another in multiple d... |
Unidata__MetPy-2272 | [
{
"changes": {
"added_entities": null,
"added_modules": null,
"edited_entities": [
"src/metpy/interpolate/slices.py:interpolate_to_slice"
],
"edited_modules": [
"src/metpy/interpolate/slices.py:interpolate_to_slice"
]
},
"file": "src/metpy/interpolate/... | Unidata/MetPy | f636fa70088a9631098902664747e4f5036fa2ed | Improve setup of pint UnitRegistry
There are now functions for `set_application_registry()` and `get_application_registry()`, so we should really look at using those for a registry. This would allow us to play nicely with other libraries/applications using pint, such as xarray-pint. Questions:
* We currently add our o... | diff --git a/src/metpy/interpolate/slices.py b/src/metpy/interpolate/slices.py
index 9ac27ed1ff..50bd70f54e 100644
--- a/src/metpy/interpolate/slices.py
+++ b/src/metpy/interpolate/slices.py
@@ -7,7 +7,7 @@ import numpy as np
import xarray as xr
from ..package_tools import Exporter
-from ..units import units
+from ... |
Unidata__MetPy-2398 | [
{
"changes": {
"added_entities": null,
"added_modules": null,
"edited_entities": null,
"edited_modules": null
},
"file": "src/metpy/io/__init__.py"
},
{
"changes": {
"added_entities": [
"src/metpy/io/station_data.py:StationLookup.__len__",
"src/metpy... | Unidata/MetPy | 4ef897cc5a306cc573abc9866a940e83db224c85 | Add station_info to docs
### What can be better?
`station_info` from `station_data.py` is explicitly exported as part of the public API, but it is not listed anywhere in the reference guide. | diff --git a/src/metpy/io/__init__.py b/src/metpy/io/__init__.py
index 4632c46c1e..c1f0aabbc3 100644
--- a/src/metpy/io/__init__.py
+++ b/src/metpy/io/__init__.py
@@ -1,11 +1,15 @@
# Copyright (c) 2015,2016,2018,2021 MetPy Developers.
# Distributed under the terms of the BSD 3-Clause License.
# SPDX-License-Identifi... |
Unidata__MetPy-2412 | [
{
"changes": {
"added_entities": null,
"added_modules": null,
"edited_entities": null,
"edited_modules": null
},
"file": "docs/conf.py"
},
{
"changes": {
"added_entities": null,
"added_modules": null,
"edited_entities": [
"src/metpy/calc/thermo.p... | Unidata/MetPy | 00951a80871ae04e9df2cd818930ced6d1ebc12a | ValueError with mpcalc.parcel_profile
### Discussed in https://github.com/Unidata/MetPy/discussions/2308
<div type='discussions-op-text'>
<sup>Originally posted by **ejt4m8** January 25, 2022</sup>
Hello!
After the release of MetPy 1.2 I wanted to go back and troubleshoot an old headache with mpcalc.parcel_path... | diff --git a/docs/_templates/autosummary/module.rst b/docs/_templates/autosummary/module.rst
index d0bc51d266..86e72828eb 100644
--- a/docs/_templates/autosummary/module.rst
+++ b/docs/_templates/autosummary/module.rst
@@ -3,54 +3,42 @@
{% include 'overrides/' ~ fullname ~ '.rst' with context %}
{% else %}
- {% i... |
Unidata__MetPy-2422 | [
{
"changes": {
"added_entities": [
"src/metpy/xarray.py:MetPyDataArrayAccessor.convert_to_base_units"
],
"added_modules": null,
"edited_entities": null,
"edited_modules": [
"src/metpy/xarray.py:MetPyDataArrayAccessor"
]
},
"file": "src/metpy/xarray.py"... | Unidata/MetPy | 0521fbd97654aa88dbce2a85fa1cb0abbb20c540 | add xarray accessor interface for `to_base_units`
### What should we add?
Per @kgoebber at today's dev call, a shorthand for pint's [`to_base_units`](https://pint.readthedocs.io/en/latest/developers_reference.html#pint.Quantity.to_base_units) would be a valuable addition to the xarray accessor | diff --git a/src/metpy/xarray.py b/src/metpy/xarray.py
index 9b0b4e0e8f..d9d0cb7edf 100644
--- a/src/metpy/xarray.py
+++ b/src/metpy/xarray.py
@@ -174,6 +174,22 @@ class MetPyDataArrayAccessor:
"""
return self.quantify().copy(data=self.unit_array.to(units))
+ def convert_to_base_units(self):
+ ... |
Unidata__MetPy-2653 | [
{
"changes": {
"added_entities": null,
"added_modules": null,
"edited_entities": [
"src/metpy/io/metar.py:parse_metar"
],
"edited_modules": [
"src/metpy/io/metar.py:parse_metar"
]
},
"file": "src/metpy/io/metar.py"
}
] | Unidata/MetPy | 72a07b9cc17617e2c858291e45696de81e139abd | visibility += int(num) / int(denom): ZeroDivisionError: division by zero
### What went wrong?
[22Z.TXT](https://github.com/Unidata/MetPy/files/9522118/22Z.TXT)
Caught a bug in the 22Z.TXT metar file from the tgftp server. I have attached the file that is causing the error. I'm unable to open the metar file at all... | diff --git a/src/metpy/io/metar.py b/src/metpy/io/metar.py
index 49c5930b59..fc56555b44 100644
--- a/src/metpy/io/metar.py
+++ b/src/metpy/io/metar.py
@@ -238,6 +238,8 @@ def parse_metar(metar_text, year, month, station_metadata=station_info):
# Handle fraction regardless
if '/' in vis_str:
... |
Unidata__MetPy-2674 | [
{
"changes": {
"added_entities": null,
"added_modules": null,
"edited_entities": [
"src/metpy/interpolate/grid.py:generate_grid",
"src/metpy/interpolate/grid.py:get_xy_steps"
],
"edited_modules": [
"src/metpy/interpolate/grid.py:generate_grid",
"src/... | Unidata/MetPy | 09b4df42c9f4bb9a8ccec07a6de7ed88e5a72aa7 | hres of interpolate_to_grid not respected
### What went wrong?
When using interpolate.interpolate_to_grid, the output grid spacing is not exactly the one specified by 'hres' parameter.
### Operating System
Linux
### Version
1.2.0
### Python Version
3.7
### Code to Reproduce
```python
from me... | diff --git a/src/metpy/interpolate/grid.py b/src/metpy/interpolate/grid.py
index 9de3e71c65..9bfeb4b8d0 100644
--- a/src/metpy/interpolate/grid.py
+++ b/src/metpy/interpolate/grid.py
@@ -18,10 +18,11 @@ def generate_grid(horiz_dim, bbox):
Parameters
----------
- horiz_dim: integer
+ horiz_dim: int or ... |
Unidata__MetPy-2691 | [
{
"changes": {
"added_entities": null,
"added_modules": null,
"edited_entities": [
"src/metpy/io/gempak.py:GempakGrid.gdxarray"
],
"edited_modules": [
"src/metpy/io/gempak.py:GempakGrid"
]
},
"file": "src/metpy/io/gempak.py"
}
] | Unidata/MetPy | acf42bc17ec954333b8a993823eab5193872c538 | gdxarray() should assign units to x and y coordinates
Is there a way to construct the proper `Dataset` with the current MetPy functionality so my attempt to plot wind barbs works?
Here's my attempt:
```python
from datetime import datetime
import xarray as xr
import metpy
from metpy.units import units
from me... | diff --git a/src/metpy/io/gempak.py b/src/metpy/io/gempak.py
index bff5f9d292..15c5b0226f 100644
--- a/src/metpy/io/gempak.py
+++ b/src/metpy/io/gempak.py
@@ -1362,6 +1362,9 @@ class GempakGrid(GempakFile):
'gempak_grid_type': ftype,
}
)
+ ... |
Unidata__MetPy-2728 | [
{
"changes": {
"added_entities": null,
"added_modules": null,
"edited_entities": [
"src/metpy/calc/thermo.py:isentropic_interpolation"
],
"edited_modules": [
"src/metpy/calc/thermo.py:isentropic_interpolation"
]
},
"file": "src/metpy/calc/thermo.py"
... | Unidata/MetPy | 47a33244cc96058b4da522779143d73961c0f7d7 | interpolate_1d not properly working on ND arrays
While `interpolate_1d` advertises support for doing a 1D interpolation across a given axis for a multidimension array, this doesn't appear to be working correctly for `k_index`:
```python
p = units.Quantity([850, 700, 500], 'hPa')
t = np.random.randn(3, 151, 151) * ... | diff --git a/ci/requirements.txt b/ci/requirements.txt
index 0047e8bd09..94db527b93 100644
--- a/ci/requirements.txt
+++ b/ci/requirements.txt
@@ -1,5 +1,5 @@
importlib_resources==5.10.0
-matplotlib==3.6.1
+matplotlib==3.6.0
numpy==1.23.3
pandas==1.5.0
pooch==1.6.0
diff --git a/src/metpy/calc/thermo.py b/src/metpy/... |
Unidata__MetPy-2808 | [
{
"changes": {
"added_entities": null,
"added_modules": null,
"edited_entities": [
"src/metpy/io/_metar_parser/metar_parser.py:Grammar._read_vis",
"src/metpy/io/_metar_parser/metar_parser.py:Grammar._read_varvis",
"src/metpy/io/_metar_parser/metar_parser.py:Grammar._rea... | Unidata/MetPy | 50b4ab7b6c2c196c09cc19cc73ee7d45077ef47f | Metar doesn't parse correctly
### What went wrong?
Metar
DEN
1/24/17 16:00
KDEN 241600Z 02010KT 1/16SM R35L/1000V1200FT FZFG VV001 M01/M02 A2954 RMK AO2 SFC VIS M1/4 T10111022
isn't parsed correctly. output dataframe (pasted below) doesn't have visibility, weather condition 'FZFG' and has a cloud coverage o... | diff --git a/src/metpy/io/_metar_parser/metar_parser.peg b/src/metpy/io/_metar_parser/metar_parser.peg
index de6d6a566f..7ad325f9ba 100644
--- a/src/metpy/io/_metar_parser/metar_parser.peg
+++ b/src/metpy/io/_metar_parser/metar_parser.peg
@@ -10,7 +10,7 @@ wind_dir <- (([\d] [\d] [\d]) / 'VAR' / 'VRB' / "///")?
wind_s... |
Unidata__MetPy-2852 | [
{
"changes": {
"added_entities": null,
"added_modules": null,
"edited_entities": [
"src/metpy/xarray.py:MetPyDataArrayAccessor.units"
],
"edited_modules": [
"src/metpy/xarray.py:MetPyDataArrayAccessor"
]
},
"file": "src/metpy/xarray.py"
}
] | Unidata/MetPy | 394fc195e3b72fd88d7cf4c1afe862588004e433 | `lat_lon_grid_deltas` (and in turn xarray grid argument magic) fails silently on xarray input with missing lat/lon units due to incorrect unit conversion
In the process of helping someone troubleshoot, I came across an example for which MetPy's automatic xarray grid argument handling failed and gave an all-`nan` result... | diff --git a/src/metpy/xarray.py b/src/metpy/xarray.py
index 545122c4c5..5559d97608 100644
--- a/src/metpy/xarray.py
+++ b/src/metpy/xarray.py
@@ -134,7 +134,12 @@ class MetPyDataArrayAccessor:
if is_quantity(self._data_array.variable._data):
return self._data_array.variable._data.units
e... |
Unidata__MetPy-2999 | [
{
"changes": {
"added_entities": null,
"added_modules": null,
"edited_entities": [
"src/metpy/calc/indices.py:bunkers_storm_motion"
],
"edited_modules": [
"src/metpy/calc/indices.py:bunkers_storm_motion"
]
},
"file": "src/metpy/calc/indices.py"
}
] | Unidata/MetPy | d75c3ba5bcba45f81ac256a0a71abe04cbe62c68 | Add non-weighted pressure-based mean function
While we have `mean_pressure_weighted`, we should add a corresponding integral-based mean calculation to go along with it. For instance, something like `bunkers_storm_motion` should probably be using that instead of `numpy.mean`, since the latter would be biased by uneven s... | diff --git a/src/metpy/calc/indices.py b/src/metpy/calc/indices.py
index 4678740a41..ef258242e8 100644
--- a/src/metpy/calc/indices.py
+++ b/src/metpy/calc/indices.py
@@ -284,9 +284,9 @@ def bunkers_storm_motion(pressure, u, v, height):
>>> sped = [5, 15, 20, 30, 50, 60] * units.knots
>>> u, v = wind_componen... |
Unidata__MetPy-3024 | [
{
"changes": {
"added_entities": [
"src/metpy/plots/mapping.py:CFProjection.name"
],
"added_modules": null,
"edited_entities": [
"src/metpy/plots/mapping.py:CFProjection.to_cartopy",
"src/metpy/plots/mapping.py:CFProjection.__str__"
],
"edited_modules"... | Unidata/MetPy | 6525d2b2fddf81ae341825a85f77c9f089a680d9 | gdxarray() returns unusable objects from "thinned GFS" files
Here's example 1:
```python
from datetime import datetime
from metpy.io import GempakGrid
import metpy
print(metpy.__version__)
gem_file_name = '/ldmdata/gempak/model/gfs/21092206_thin.gem'
gem_file = GempakGrid(gem_file_name)
plot_time = date... | diff --git a/src/metpy/plots/mapping.py b/src/metpy/plots/mapping.py
index 7a241b4ca2..0ee2f87538 100644
--- a/src/metpy/plots/mapping.py
+++ b/src/metpy/plots/mapping.py
@@ -43,6 +43,11 @@ class CFProjection:
return {cartopy_name: source[cf_name] for cartopy_name, cf_name in mapping
if cf_nam... |
Unidata__MetPy-3056 | [
{
"changes": {
"added_entities": null,
"added_modules": null,
"edited_entities": [
"src/metpy/calc/thermo.py:lfc",
"src/metpy/calc/thermo.py:el"
],
"edited_modules": [
"src/metpy/calc/thermo.py:lfc",
"src/metpy/calc/thermo.py:el"
]
},
"... | Unidata/MetPy | 3bfad0409bb80fa04b4556d06d7073b4dafee8cf | el and lfc don't adjust profile for nans
As noted:
It looks that the "_remove_nans()" remove nans for p, T, and Td.
However, when I provide "parcel_profile" like the example, it is not touched, so I think the error occurs because of the difference of length between prof and other variables.
_Originally ... | diff --git a/src/metpy/calc/thermo.py b/src/metpy/calc/thermo.py
index 483a6f6b70..327aff534c 100644
--- a/src/metpy/calc/thermo.py
+++ b/src/metpy/calc/thermo.py
@@ -667,12 +667,15 @@ def lfc(pressure, temperature, dewpoint, parcel_temperature_profile=None, dewpoi
Renamed ``dewpt``,``dewpoint_start`` parameter... |
Unidata__MetPy-3103 | [
{
"changes": {
"added_entities": null,
"added_modules": null,
"edited_entities": [
"src/metpy/interpolate/one_dimension.py:_strip_matching_units"
],
"edited_modules": [
"src/metpy/interpolate/one_dimension.py:_strip_matching_units"
]
},
"file": "src/me... | Unidata/MetPy | 77447f1421ab5dfc1db5f6e177179909ca5453cc | interpolate.log_interpolate_1d fails with Xarray input of more than 3D (Numpy succeeds)
- Description: `metpy.interpolate.interpolate_1d` has `no implementation found for 'numpy.apply_along_axis'` error for cases where the input is `xarray.Dataarray` and has more than 3 dimensions (e.g. 4th dim of `time`). Function wor... | diff --git a/src/metpy/interpolate/one_dimension.py b/src/metpy/interpolate/one_dimension.py
index bead0796de..f12bcea96f 100644
--- a/src/metpy/interpolate/one_dimension.py
+++ b/src/metpy/interpolate/one_dimension.py
@@ -239,4 +239,6 @@ def _strip_matching_units(*args):
if all(hasattr(arr, 'units') for arr in ar... |
Unidata__MetPy-3188 | [
{
"changes": {
"added_entities": null,
"added_modules": null,
"edited_entities": [
"src/metpy/io/nexrad.py:Level3XDRParser.__init__",
"src/metpy/io/nexrad.py:Level3XDRParser.unpack_uint",
"src/metpy/io/nexrad.py:Level3XDRParser.unpack_int",
"src/metpy/io/nexrad.... | Unidata/MetPy | 1a53dd232914227555ccc0e4a98a1d90a287f006 | add_station_lat_lon yields columns with object dtype
```python
df = pd.DataFrame({'station': ['KOUN', 'KVPZ', 'KDEN', 'PAAA']})
df = add_station_lat_lon(df, 'station')
df.info()
```
gives
```
<class 'pandas.core.frame.DataFrame'>
RangeIndex: 4 entries, 0 to 3
Data columns (total 3 columns):
# Column No... | diff --git a/.github/workflows/backport-prs.yml b/.github/workflows/backport-prs.yml
index f93bfbc9b7..5246fdb47a 100644
--- a/.github/workflows/backport-prs.yml
+++ b/.github/workflows/backport-prs.yml
@@ -16,7 +16,7 @@ jobs:
if: github.event.pull_request.merged && contains( github.event.pull_request.labels.*.nam... |
Unidata__MetPy-3242 | [
{
"changes": {
"added_entities": [
"src/metpy/calc/thermo.py:_dewpoint_from_specific_humidity"
],
"added_modules": [
"src/metpy/calc/thermo.py:_dewpoint_from_specific_humidity"
],
"edited_entities": [
"src/metpy/calc/thermo.py:relative_humidity_from_dewpoint... | Unidata/MetPy | 83308c322a57221566f2bd25b2a1b026d82291ef | Relative Humidity Inconsistency
### What should we add?
MetPy is inconsistent in its definition of relative humidity. For review, there are two definitions:
1) The WMO favors $w/w_s$
2) Most thermo textbooks (e.g., Curry and Webster p. 113) and the [AMS](https://glossary.ametsoc.org/wiki/Relative_humidity) prefer $e... | diff --git a/pyproject.toml b/pyproject.toml
index f6b032aaee..cfae651fb5 100644
--- a/pyproject.toml
+++ b/pyproject.toml
@@ -107,6 +107,8 @@ line-length = 95
exclude = ["docs", "build", "src/metpy/io/_metar_parser/metar_parser.py"]
select = ["A", "B", "C", "D", "E", "E226", "F", "G", "I", "N", "Q", "R", "S", "T", "... |
Unidata__MetPy-3307 | [
{
"changes": {
"added_entities": null,
"added_modules": null,
"edited_entities": [
"src/metpy/calc/basic.py:heat_index"
],
"edited_modules": [
"src/metpy/calc/basic.py:heat_index"
]
},
"file": "src/metpy/calc/basic.py"
}
] | Unidata/MetPy | f09de38909137559ed8a62565abf03241aa89916 | heat_index does not return same units as temperature
### What went wrong?
The `heat_index` calculation does not return the same units as the temperature initially provided. I believe this can be fixed by adding `.to(temperature.units)` right before the return similar to the `windchill` and `apparent_temperature` calcu... | diff --git a/ci/linting_requirements.txt b/ci/linting_requirements.txt
index b698df8f81..d6739d64c7 100644
--- a/ci/linting_requirements.txt
+++ b/ci/linting_requirements.txt
@@ -7,7 +7,7 @@ pyflakes==3.1.0
flake8-continuation==1.0.5
flake8-copyright==0.2.4
flake8-isort==6.1.1
-isort==5.12.0
+isort==5.13.0
flake8-r... |
Unidata__MetPy-3323 | [
{
"changes": {
"added_entities": null,
"added_modules": null,
"edited_entities": [
"src/metpy/calc/thermo.py:isentropic_interpolation_as_dataset"
],
"edited_modules": [
"src/metpy/calc/thermo.py:isentropic_interpolation_as_dataset"
]
},
"file": "src/me... | Unidata/MetPy | 213d1a07a6ae48a78a9c7149942d59a9016c49c0 | isentropic_interpolation_as_dataset returns unplottable dataset
### What went wrong?
Students are great at inadvertently stress-testing MetPy. Here is our latest discovery.
The error took a while to figure out (especially in the original code where the offending line is far away from the declarative plotting sectio... | diff --git a/.github/workflows/code-analysis.yml b/.github/workflows/code-analysis.yml
index 301d0c0ffd..43d963a1f0 100644
--- a/.github/workflows/code-analysis.yml
+++ b/.github/workflows/code-analysis.yml
@@ -31,9 +31,9 @@ jobs:
uses: actions/checkout@v4
- name: Initialize CodeQL
- uses: github/cod... |
Unidata__MetPy-3324 | [
{
"changes": {
"added_entities": null,
"added_modules": null,
"edited_entities": [
"src/metpy/calc/thermo.py:isentropic_interpolation",
"src/metpy/calc/thermo.py:isentropic_interpolation_as_dataset"
],
"edited_modules": [
"src/metpy/calc/thermo.py:isentropic... | Unidata/MetPy | 34d14b293c9e75dfff5422c0461d48731916d773 | Units issue with isentropic_interpolation_as_dataset and CONUS404 data
### What went wrong?
I am trying to use **metpy.calc.isentropic_interpolation_as_dataset** to interpolate CONUS404 data to isentropic levels. The CONUS404 data is produced using WRF v3.9.1.1. As such, I am using xarray and xWRF to read and proces... | diff --git a/src/metpy/calc/thermo.py b/src/metpy/calc/thermo.py
index 0f36e33efd..79571066f5 100644
--- a/src/metpy/calc/thermo.py
+++ b/src/metpy/calc/thermo.py
@@ -2624,7 +2624,7 @@ def isentropic_interpolation(levels, pressure, temperature, *args, vertical_dim=
One-dimensional array of desired potential te... |
Unidata__MetPy-3347 | [
{
"changes": {
"added_entities": null,
"added_modules": null,
"edited_entities": [
"src/metpy/interpolate/slices.py:interpolate_to_slice"
],
"edited_modules": [
"src/metpy/interpolate/slices.py:interpolate_to_slice"
]
},
"file": "src/metpy/interpolate/... | Unidata/MetPy | c2b56bb09fad3034e8c5fd3b28fbafc2b52241b9 | UndefinedUnitError: 'dBZ' is not defined in the unit registry
### What went wrong?
Hello everyone!
I want to create a radar reflectivity profile, but I encountered an issue when using the cross_section function. It seems that the unit 'dBZ' for reflectivity is not defined, although the dataset used has already defin... | diff --git a/.gitignore b/.gitignore
index 3b8f0987ca..b4ee237550 100644
--- a/.gitignore
+++ b/.gitignore
@@ -29,3 +29,4 @@ docs/api/generated
docs/api/areas.rst
examples/scripts
test_output/
+docs/sg_execution_times.rst
diff --git a/src/metpy/interpolate/slices.py b/src/metpy/interpolate/slices.py
index b11199565e... |
Unidata__MetPy-3437 | [
{
"changes": {
"added_entities": null,
"added_modules": null,
"edited_entities": [
"src/metpy/xarray.py:MetPyDataArrayAccessor._generate_coordinate_map"
],
"edited_modules": [
"src/metpy/xarray.py:MetPyDataArrayAccessor"
]
},
"file": "src/metpy/xarray.... | Unidata/MetPy | 8f510ae51fe0478ba208711bb7468efca0296ade | mpcalc.isentropic_interpolation_as_dataset "vertical attribute is not available."
I get an error "vertical attribute is not available." when interpolating bitwise vortices to isentropic surfaces using the mpcalc.isentropic_interpolation_as_dataset function.Here's the code and the specifics of the error reported:
```... | diff --git a/src/metpy/xarray.py b/src/metpy/xarray.py
index 2ccb36ce0a..ab16f76802 100644
--- a/src/metpy/xarray.py
+++ b/src/metpy/xarray.py
@@ -338,15 +338,16 @@ class MetPyDataArrayAccessor:
def _generate_coordinate_map(self):
"""Generate a coordinate map via CF conventions and other methods."""
... |
Unidata__MetPy-985 | [
{
"changes": {
"added_entities": null,
"added_modules": null,
"edited_entities": null,
"edited_modules": null
},
"file": "src/metpy/calc/__init__.py"
},
{
"changes": {
"added_entities": null,
"added_modules": null,
"edited_entities": null,
"edited_... | Unidata/MetPy | 4acc25b959570dc3971781f315d596965330bfe7 | Set __module__ on exported functions, etc.
Functions and classes have a `__module__` attribute, which IPython and Jupyter use when printing out a name:
```python
from metpy.calc import geostrophic_wind
geostrophic_wind
> <function metpy.calc.kinematics.geostrophic_wind(heights, f, dx, dy)>
```
It would be nice if... | diff --git a/src/metpy/calc/__init__.py b/src/metpy/calc/__init__.py
index 5c1f22aaff..faf6b112c5 100644
--- a/src/metpy/calc/__init__.py
+++ b/src/metpy/calc/__init__.py
@@ -10,6 +10,7 @@ from .kinematics import * # noqa: F403
from .thermo import * # noqa: F403
from .tools import * # noqa: F403
from .turbulence ... |
Unidata__siphon-143 | [
{
"changes": {
"added_entities": null,
"added_modules": null,
"edited_entities": [
"siphon/ncss.py:NCSS.validate_query"
],
"edited_modules": [
"siphon/ncss.py:NCSS"
]
},
"file": "siphon/ncss.py"
}
] | Unidata/siphon | e61c876c455ad6250594eddec57d08d454e9e611 | NCSS validate_query with no variables
``` python
from siphon.ncss import NCSS
ncss = NCSS('http://thredds.ucar.edu/thredds/ncss/nws/metar/ncdecoded/Metar_Station_Data_fc.cdmr')
query = ncss.query()
ncss.validate_query(query)
```
returns `set()`
Looks like the nice short-circuit behavior results in the return of the e... | diff --git a/siphon/ncss.py b/siphon/ncss.py
index 7f1a971e..da1a11e8 100644
--- a/siphon/ncss.py
+++ b/siphon/ncss.py
@@ -88,7 +88,7 @@ class NCSS(HTTPEndPoint):
"""
# Make sure all variables are in the dataset
- return query.var and all(var in self.variables for var in query.var)
+ r... |
Unidata__siphon-166 | [
{
"changes": {
"added_entities": [
"siphon/catalog.py:TDSCatalog.__str__",
"siphon/catalog.py:CatalogRef.__str__",
"siphon/catalog.py:Dataset.__str__"
],
"added_modules": null,
"edited_entities": null,
"edited_modules": [
"siphon/catalog.py:DatasetCo... | Unidata/siphon | bd0a6e36c8390d9bb9b072e0a1a95ca4f44ee1d5 | Improve catalog dataset string representation
Currently if we look at the catalog of GOES-16 data:
```python
from datetime import datetime
from siphon.catalog import TDSCatalog
date = datetime.utcnow()
channel = 8
region = 'Mesoscale-2'
cat = TDSCatalog('http://thredds-test.unidata.ucar.edu/thredds/catalo... | diff --git a/environment.yml b/environment.yml
index b6005bf3..7265b1d7 100755
--- a/environment.yml
+++ b/environment.yml
@@ -13,6 +13,7 @@ dependencies:
- sphinx-gallery
- doc8
- pytest
+ - pytest-catchlog
- pytest-cov
- pytest-flake8
- pytest-runner
diff --git a/siphon/catalog.py b/siphon/catalog.... |
Unidata__siphon-206 | [
{
"changes": {
"added_entities": null,
"added_modules": null,
"edited_entities": [
"siphon/simplewebservice/iastate.py:IAStateUpperAir._get_data",
"siphon/simplewebservice/iastate.py:IAStateUpperAir._get_data_raw"
],
"edited_modules": [
"siphon/simplewebserv... | Unidata/siphon | e99953a89c35afd15c6e24a54fa0ebba4e927946 | Add time to upper air data
Current the returned data does not have a column for time, since this isn't provided as a column in the output--but it *is* in the text header. It would be nice to parse this and add as a column so that we have a self-contained dataset. It's probably also needed when we try to handle requesti... | diff --git a/siphon/simplewebservice/iastate.py b/siphon/simplewebservice/iastate.py
index f31d8cfa..cb931967 100644
--- a/siphon/simplewebservice/iastate.py
+++ b/siphon/simplewebservice/iastate.py
@@ -3,6 +3,7 @@
# SPDX-License-Identifier: BSD-3-Clause
"""Read upper air data from the IA State archives."""
+from d... |
Unidata__siphon-242 | [
{
"changes": {
"added_entities": null,
"added_modules": null,
"edited_entities": null,
"edited_modules": null
},
"file": "examples/Basic_Usage.py"
},
{
"changes": {
"added_entities": null,
"added_modules": null,
"edited_entities": [
"siphon/catal... | Unidata/siphon | f0571050bf34460038f0841954ea7c9b828bccc5 | Better Server Error Handling
When hitting a data server that is down, I receive a seemingly random assortment of inconsistent error messages each time I do so. For example, Java errors, even "too many open file" errors. It would be great to be given a single, consistent "Server temporarily unavailable" error so I know ... | diff --git a/environment.yml b/environment.yml
index 2278a3d5..2249c72e 100755
--- a/environment.yml
+++ b/environment.yml
@@ -12,6 +12,7 @@ dependencies:
- jupyter
- sphinx
- sphinx-gallery
+ - pillow
- doc8
- pytest
- pytest-cov
diff --git a/examples/Basic_Usage.py b/examples/Basic_Usage.py
index 0... |
VTimofeenko__confluence_poster-25 | [
{
"changes": {
"added_entities": null,
"added_modules": null,
"edited_entities": [
"confluence_poster/main.py:main"
],
"edited_modules": [
"confluence_poster/main.py:main"
]
},
"file": "confluence_poster/main.py"
}
] | VTimofeenko/confluence_poster | 33f9300cc47b0d5b7d77a251519599bd044813cb | Handle no config by prompting to create one
Depends on #11 | diff --git a/confluence_poster/main.py b/confluence_poster/main.py
index b76a172..3e26f22 100644
--- a/confluence_poster/main.py
+++ b/confluence_poster/main.py
@@ -497,7 +497,11 @@ def main(
state.minor_edit = minor_edit
typer.echo("Reading config")
- confluence_config = load_config(config)
... |
ValvePython__steam-168 | [
{
"changes": {
"added_entities": null,
"added_modules": null,
"edited_entities": [
"steam/client/__init__.py:SteamClient.connect",
"steam/client/__init__.py:SteamClient._bootstrap_cm_list_from_file",
"steam/client/__init__.py:SteamClient._handle_cm_list",
"steam... | ValvePython/steam | a0201998fbb3665c5b2c28127274e23bf8841c17 | CMServerList should fallback to discovery by default
Instead of keeping a bootstrap list up to date, when the server list is empty and an attempt is made to iterate it, we should automatically fallback to some discovery method.
Either using `cm0.steampowered.com` or via webapi | diff --git a/steam/client/__init__.py b/steam/client/__init__.py
index 19a93cc..fd34e75 100644
--- a/steam/client/__init__.py
+++ b/steam/client/__init__.py
@@ -48,7 +48,6 @@ class SteamClient(CMClient, BuiltinBase):
"""After a new login key is accepted
"""
- _cm_servers_timestamp = None # used to ... |
ValvePython__steam-309 | [
{
"changes": {
"added_entities": [
"steam/core/crypto.py:md5_hash"
],
"added_modules": [
"steam/core/crypto.py:md5_hash"
],
"edited_entities": null,
"edited_modules": null
},
"file": "steam/core/crypto.py"
},
{
"changes": {
"added_entitie... | ValvePython/steam | caa7072cf0148d21593383e52ebd00a1ae8cf9ff | SteamID: implement CSGO friend code
https://github.com/xPaw/SteamID.php/commit/fe934ce802f8aadc6fee1c3b47cd1a82f2328d75 | diff --git a/steam/core/crypto.py b/steam/core/crypto.py
index 6fb2867..583bbde 100644
--- a/steam/core/crypto.py
+++ b/steam/core/crypto.py
@@ -6,7 +6,7 @@ from os import urandom as random_bytes
from struct import pack
from base64 import b64decode
-from Cryptodome.Hash import SHA1, HMAC
+from Cryptodome.Hash impor... |
ValvePython__steam-359 | [
{
"changes": {
"added_entities": null,
"added_modules": null,
"edited_entities": null,
"edited_modules": null
},
"file": "setup.py"
},
{
"changes": {
"added_entities": null,
"added_modules": null,
"edited_entities": [
"steam/game_servers.py:Struc... | ValvePython/steam | 061ca33842c9ec5aa7c0866d20cbeed0759d5ea5 | Option to return a2s_rules as bytes instead of strings
The `steam.game_servers.a2s_rules` function currently returns the server rules as a dictionary of strings to strings (`Dict[str, str]`), which is suitable for plain text rules. However, some game servers use the Steam `A2S_RULES` API to return binary data. For exam... | diff --git a/requirements.txt b/requirements.txt
index 92661a9..14293fb 100644
--- a/requirements.txt
+++ b/requirements.txt
@@ -3,7 +3,8 @@ pycryptodomex>=3.7.0
requests>=2.9.1
vdf>=3.3
gevent>=1.3.0
-protobuf>=3.0.0
+protobuf>~3.0; python_version >= '3'
+protobuf<3.18.0; python_version < '3'
gevent-eventemitter~=... |
ValvePython__vpk-19 | [
{
"changes": {
"added_entities": [
"vpk/cli.py:run"
],
"added_modules": [
"vpk/cli.py:run"
],
"edited_entities": [
"vpk/cli.py:make_argparser",
"vpk/cli.py:make_filter_func",
"vpk/cli.py:main"
],
"edited_modules": [
"vpk/c... | ValvePython/vpk | 8e65de261542bdfc38ea3ddf9c68394b9399bea2 | cli: add flag to negate the regex or filter matching | diff --git a/README.rst b/README.rst
index 16e2392..6b9b958 100644
--- a/README.rst
+++ b/README.rst
@@ -80,7 +80,7 @@ A command line utility is also included
.. code:: text
usage: vpk [-h] [--version] [-l] [-la] [-x OUT_LOCATION] [-nd] [-t] [-c DIR]
- [-p] [-f WILDCARD | -re REGEX | -name WILDCAR... |
Viatorus__quom-34 | [
{
"changes": {
"added_entities": [
"quom/__main__.py:run"
],
"added_modules": [
"quom/__main__.py:run"
],
"edited_entities": [
"quom/__main__.py:main"
],
"edited_modules": [
"quom/__main__.py:main"
]
},
"file": "quom/__main_... | Viatorus/quom | b4bb7665357892411081b86b7c33c0ffc18d2f1b | Feature request - Additional directories to search for sources
Hi, I found this package very useful, but when trying to use it - encounter with a small problem. The case when sources are located in different directory then their headers - are not supported. The common folder structure of any project can be as follows:
... | diff --git a/README.md b/README.md
index db84fbb..4486b8c 100644
--- a/README.md
+++ b/README.md
@@ -44,6 +44,10 @@ optional arguments:
--trim, -t Reduce continuous line breaks to one. Default: True
--include_directory INCLUDE_DIRECTORY, -I INCLUDE_DIRECTORY
Add include directo... |
Viatorus__quom-43 | [
{
"changes": {
"added_entities": null,
"added_modules": null,
"edited_entities": [
"src/quom/quom.py:Quom.__process_file"
],
"edited_modules": [
"src/quom/quom.py:Quom"
]
},
"file": "src/quom/quom.py"
}
] | Viatorus/quom | 8d13a41baea1a930d27a869ff468aa72fe25b100 | option to skip already included files
Hello and thanks for creating such awesome utility! I'm using it in my [CTRE](https://github.com/hanickadot/compile-time-regular-expressions) project. I noticed sometimes quom include same file multiple times.
Would be possible to add an option to ignore already included files?... | diff --git a/src/quom/quom.py b/src/quom/quom.py
index 5dbaad9..5f7d51c 100644
--- a/src/quom/quom.py
+++ b/src/quom/quom.py
@@ -80,6 +80,7 @@ class Quom:
raise QuomError('Include not found: "{}"'.format(include_path))
# Skip already processed files.
+ file_path = file_path.resolve()
... |
Viatorus__quom-44 | [
{
"changes": {
"added_entities": null,
"added_modules": null,
"edited_entities": [
"src/quom/__main__.py:main"
],
"edited_modules": [
"src/quom/__main__.py:main"
]
},
"file": "src/quom/__main__.py"
},
{
"changes": {
"added_entities": null... | Viatorus/quom | 1c180ae75c91edf5c174053332aa96007fe13caa | Open files with UTF-8 encoding
On Windows, Python uses ANSI encoding as its default text encoding when opening files. This is fine if you only use ASCII characters since ANSI is compatible with ASCII. But otherwise you will get errors like the following:
```py
File "C:\Users\Username\AppData\Roaming\Python\Python39... | diff --git a/src/quom/__main__.py b/src/quom/__main__.py
index 77d99b3..bb62485 100644
--- a/src/quom/__main__.py
+++ b/src/quom/__main__.py
@@ -29,6 +29,8 @@ def main(args: List[str]):
parser.add_argument('--source_directory', '-S', type=str, action='append', default=['.'],
help='Set the ... |
Viatorus__quom-46 | [
{
"changes": {
"added_entities": [
"src/quom/quom.py:Quom.__write_line_break_if_missing"
],
"added_modules": null,
"edited_entities": [
"src/quom/quom.py:Quom.__init__",
"src/quom/quom.py:Quom.__write_token",
"src/quom/quom.py:Quom.__scan_for_source_files_... | Viatorus/quom | 4633b5aaba35454c425227ec498ea1e19caade39 | when source files have no newline at EOF, content of next file is concatenated right after last closing curly bracket
When one of source files has no newline at EOF, the "#include ..."s of the next file appears right after the last closing curly bracket and that causes a compilation error.
I know it's a trivial probl... | diff --git a/src/quom/quom.py b/src/quom/quom.py
index 3cf4e13..0f6f7cd 100644
--- a/src/quom/quom.py
+++ b/src/quom/quom.py
@@ -1,3 +1,4 @@
+import os
import re
from pathlib import Path
from queue import Queue
@@ -46,6 +47,7 @@ class Quom:
self.__processed_files = set()
self.__source_files = Queue... |
VictorPelaez__coral-reef-optimization-algorithm-43 | [
{
"changes": {
"added_entities": null,
"added_modules": null,
"edited_entities": [
"cro/cro.py:CRO.__init__",
"cro/cro.py:CRO.fitness",
"cro/cro.py:CRO.larvaesettling",
"cro/cro.py:CRO.budding",
"cro/cro.py:CRO.depredation",
"cro/cro.py:CRO.fit"
... | VictorPelaez/coral-reef-optimization-algorithm | 9939a280c87090b7ae575a23670f49a265ad017a | create a opt_multiplier (-1 or 1) with opt argument
One of the main point suggested in Issue #22.
Using opt argument, create a self.opt_multiplier (1, -1)
It looks an improvement in 2 functions:
- budding()
```
if self.opt=='max': ind = np.argsort(-fitness);
else: ind = np.argsort(fitnes... | diff --git a/cro/cro.py b/cro/cro.py
index 44c17ae..ebc560b 100644
--- a/cro/cro.py
+++ b/cro/cro.py
@@ -20,6 +20,7 @@ class CRO(object):
self.Pd = Pd
self.fitness_coral = fitness_coral
self.opt = opt
+ self.opt_multiplier = -1 if opt == "max" else 1
self.L = ... |
Viicos__flake8-pydantic-11 | [
{
"changes": {
"added_entities": null,
"added_modules": null,
"edited_entities": [
"src/flake8_pydantic/_utils.py:_has_pydantic_model_base",
"src/flake8_pydantic/_utils.py:_has_field_function",
"src/flake8_pydantic/_utils.py:_has_pydantic_method",
"src/flake8_py... | Viicos/flake8-pydantic | bf0572d9c686adadca4b18b719f46b1ad4206ce5 | False positives for `is_pydantic_model`
The following checks:
- `_has_field_function`
- `_has_pydantic_method`
Raises false positives with the following code:
- Using `django-import-export`:
```python
class SomeResource(resources.ModelResource):
user = Field(attribute="user")
```
- When a `model_*`... | diff --git a/src/flake8_pydantic/_utils.py b/src/flake8_pydantic/_utils.py
index edeba4f..49268cc 100644
--- a/src/flake8_pydantic/_utils.py
+++ b/src/flake8_pydantic/_utils.py
@@ -16,7 +16,7 @@ def get_decorator_names(decorator_list: list[ast.expr]) -> set[str]:
return names
-def _has_pydantic_model_base(node... |
Viicos__jsonlogic-25 | [
{
"changes": {
"added_entities": null,
"added_modules": null,
"edited_entities": null,
"edited_modules": null
},
"file": "docs/source/conf.py"
},
{
"changes": {
"added_entities": [
"src/jsonlogic/core.py:JSONLogicExpression._parse_impl",
"src/jsonlog... | Viicos/jsonlogic | f60caf6fabb07ec70fbc25af664c345dbb3887fa | Add support for operators inside arrays
As shown in the failing test, `["2000-01-01", {"var": "/my_date"}]` is treated as is, as a literal.
https://github.com/Viicos/jsonlogic/blob/d96289027c5f28ed703a55c4b276d3bab954fb2d/tests/operators/test_typecheck.py#L235-L245 | diff --git a/docs/source/conf.py b/docs/source/conf.py
index f46a4aa..8a0d020 100644
--- a/docs/source/conf.py
+++ b/docs/source/conf.py
@@ -13,7 +13,7 @@ sys.path.insert(0, str(Path(__file__).parents[2] / "src"))
project = "python-jsonlogic"
copyright = "2024, Victorien"
author = "Victorien"
-release = "0.1"
+relea... |
Vipul-Cariappa__py-utility-7 | [
{
"changes": {
"added_entities": null,
"added_modules": null,
"edited_entities": [
"pyutility/memoryutil.py:memoryit",
"pyutility/memoryutil.py:limit_memory"
],
"edited_modules": [
"pyutility/memoryutil.py:memoryit",
"pyutility/memoryutil.py:limit_me... | Vipul-Cariappa/py-utility | 8f66fc1fc569c34798865ab063f1da4e7753c9d5 | Multiprocessing Errors
Python throws EOFError and RuntimeError, when decorator is used. Even when `__name__ == __main__` if statement is present it throws PicklingError. This is because multiprocessing is using spawn to create new processes. Some details can be found here: [StackOverFlow Question](https://stackoverflow... | diff --git a/README.md b/README.md
index e6336ee..47feb7f 100644
--- a/README.md
+++ b/README.md
@@ -4,7 +4,8 @@ Utility functions for managing and monitoring python resources.
## installation
<pre><code>pip install py-utility</code></pre>
-## Decorator Function
+
+## Documentation
### memoryit
memoryit returns... |
VirtusLab__git-machete-179 | [
{
"changes": {
"added_entities": null,
"added_modules": null,
"edited_entities": [
"git_machete/cmd.py:MacheteClient.read_definition_file",
"git_machete/cmd.py:launch"
],
"edited_modules": [
"git_machete/cmd.py:MacheteClient",
"git_machete/cmd.py:lau... | VirtusLab/git-machete | 974914523542045104806e52be8135027603f771 | Line numbers displayed in errors refer to non-empty lines, not all lines
.git/machete file:
```
master
develop
develop
```
The empty lines lead to an error in `git machete status`:
`.git/machete, line 3: branch develop re-appears in the tree definition. Edit the definition file manually with git ma... | diff --git a/git_machete/cmd.py b/git_machete/cmd.py
index 03f722b..9772a79 100644
--- a/git_machete/cmd.py
+++ b/git_machete/cmd.py
@@ -89,7 +89,7 @@ class MacheteClient:
def read_definition_file(self, verify_branches: bool = True) -> None:
with open(self._definition_file_path) as f:
- lines... |
VirtusLab__git-machete-248 | [
{
"changes": {
"added_entities": null,
"added_modules": null,
"edited_entities": [
"git_machete/client.py:MacheteClient.checkout_github_prs",
"git_machete/client.py:MacheteClient.__get_path_from_pr_chain"
],
"edited_modules": [
"git_machete/client.py:Machete... | VirtusLab/git-machete | b9fc728f29660c64cd850534e0f2631060706e73 | Check first if given pull request is closed in `github checkout-pr`
Github Api returns all opened pull requests after `GET` on [pulls endpoint](https://docs.github.com/en/rest/reference/pulls).
During `github checkout-pr` on pull request which is already closed, git-machete ends up with message:
```
$ git machete ... | diff --git a/git_machete/client.py b/git_machete/client.py
index 146e994..7cdabcf 100644
--- a/git_machete/client.py
+++ b/git_machete/client.py
@@ -16,10 +16,10 @@ from git_machete.constants import (
from git_machete.exceptions import MacheteException, StopInteraction
from git_machete.git_operations import GitContex... |
VirtusLab__git-machete-327 | [
{
"changes": {
"added_entities": null,
"added_modules": null,
"edited_entities": [
"git_machete/client.py:MacheteClient.checkout_github_prs"
],
"edited_modules": [
"git_machete/client.py:MacheteClient"
]
},
"file": "git_machete/client.py"
}
] | VirtusLab/git-machete | 78be40e5ad31092d2a7424d9aadf433be588335d | Remote incorrectly assigned for a newly-checked-out parent branch in `github checkout-prs`
Here's the full log:
<details>
<summary>Log of github checkout-prs</summary>
<pre>
➜ 18:42 ~/git-machete develop $ git machete s -l
master v3.4.1
│
│ Issue #233: Provide support for 4th location of GitHub token. ... | diff --git a/git_machete/client.py b/git_machete/client.py
index 2648556..cd389c1 100644
--- a/git_machete/client.py
+++ b/git_machete/client.py
@@ -1847,6 +1847,8 @@ class MacheteClient:
remote, (org, repo) = self.__derive_remote_and_github_org_and_repo()
current_user: Optional[str] = git_machete.git... |
VirtusLab__git-machete-330 | [
{
"changes": {
"added_entities": null,
"added_modules": null,
"edited_entities": [
"git_machete/cli.py:update_cli_opts_using_parsed_args"
],
"edited_modules": [
"git_machete/cli.py:update_cli_opts_using_parsed_args"
]
},
"file": "git_machete/cli.py"
... | VirtusLab/git-machete | 18f7e32640cab8483c32a231a478c23c1a50ec67 | `AttributeError: 'str' object has no attribute 'full_name'` due to (?) mistyped `CommandLineOptions.opt_branch`
For an already existing, but not yet managed branch `foo/bar`:
```
$ git machete add foo/bar
Traceback (most recent call last):
File "/usr/local/bin/git-machete", line 4, in <module>
__import__('... | diff --git a/git_machete/cli.py b/git_machete/cli.py
index 19a6a38..8824ec9 100644
--- a/git_machete/cli.py
+++ b/git_machete/cli.py
@@ -358,15 +358,25 @@ def create_cli_parser() -> argparse.ArgumentParser:
def update_cli_opts_using_parsed_args(
cli_opts: git_machete.options.CommandLineOptions,
parse... |
VirtusLab__git-machete-348 | [
{
"changes": {
"added_entities": null,
"added_modules": null,
"edited_entities": [
"git_machete/client.py:MacheteClient.__pick_remote",
"git_machete/client.py:MacheteClient.handle_untracked_branch",
"git_machete/client.py:MacheteClient.create_github_pr",
"git_ma... | VirtusLab/git-machete | 931fd2c58aaebdc325e1fd2c9ceacecee80f72e7 | `github create-pr`: check if base branch for PR exists in remote
Attempt to create a pull request with base branch being already deleted from remote ends up with `Unprocessable Entity` error. (example in #332).
Proposed solution:
Perform `git fetch <remote>` at the beginning of `create-pr`. if base branch is not pr... | diff --git a/git_machete/client.py b/git_machete/client.py
index 556fa3d..d1d9146 100644
--- a/git_machete/client.py
+++ b/git_machete/client.py
@@ -1631,6 +1631,7 @@ class MacheteClient:
*,
branch: LocalBranchShortName,
is_called_from_traverse: bool,
+ is_called_from_c... |
VirtusLab__git-machete-350 | [
{
"changes": {
"added_entities": null,
"added_modules": null,
"edited_entities": [
"git_machete/exceptions.py:UnprocessableEntityHTTPError.__init__"
],
"edited_modules": [
"git_machete/exceptions.py:UnprocessableEntityHTTPError"
]
},
"file": "git_mache... | VirtusLab/git-machete | 5c5bef4a52ef72bdb4bc095210d15acdc1826ffd | Is the check for PR existence still needed now that we read the body of 422 response?
`git_machete.github.create_pull_request`:
```
prs: List[GitHubPullRequest] = derive_pull_requests(org, repo)
pr_found: Optional[GitHubPullRequest] = find_or_none(lambda pr: pr.base == base and pr.head == head, prs)
i... | diff --git a/git_machete/exceptions.py b/git_machete/exceptions.py
index a1f9893..ae09ea3 100644
--- a/git_machete/exceptions.py
+++ b/git_machete/exceptions.py
@@ -21,7 +21,7 @@ class UnprocessableEntityHTTPError(MacheteException):
or creating a pull request for a branch that already has a PR.
"""
def _... |
VirtusLab__git-machete-353 | [
{
"changes": {
"added_entities": null,
"added_modules": null,
"edited_entities": null,
"edited_modules": null
},
"file": "git_machete/__init__.py"
},
{
"changes": {
"added_entities": null,
"added_modules": null,
"edited_entities": [
"git_machete/... | VirtusLab/git-machete | b5ce4b7f67ea347ff0e1357a61d5412027218a87 | Add `t` as an alias for `traverse` (just as `s` is for `status`) | diff --git a/RELEASE_NOTES.md b/RELEASE_NOTES.md
index 4cb7056..395fed7 100644
--- a/RELEASE_NOTES.md
+++ b/RELEASE_NOTES.md
@@ -1,5 +1,9 @@
# Release notes
+## New in git-machete 3.6.0
+
+- added: `t` alias for `traverse` command
+
## New in git-machete 3.5.0
- added: new way of acquiring the github token (from... |
VirtusLab__git-machete-354 | [
{
"changes": {
"added_entities": null,
"added_modules": null,
"edited_entities": null,
"edited_modules": null
},
"file": "git_machete/__init__.py"
},
{
"changes": {
"added_entities": null,
"added_modules": null,
"edited_entities": [
"git_machete/... | VirtusLab/git-machete | d47818c3e89b687ca283fef57c824f9a0577c650 | `git machete github checkout-prs` should enable checking out multiple PRs at once
```
git machete github checkout-prs 123 456 789
git machete github checkout-prs --mine
git machete github checkout-prs --by=PawelLipski
git machete github checkout-prs --all
```
This will make entry into the tool for newcomers smo... | diff --git a/README.md b/README.md
index dc94910..c8b62eb 100644
--- a/README.md
+++ b/README.md
@@ -160,9 +160,9 @@ Annotate the branches with GitHub PR numbers: <br/>
git machete github anno-prs
```
-Check out the PR into local branch, also traverse chain of pull requests upwards, adding branches one by one to gi... |
VirtusLab__git-machete-463 | [
{
"changes": {
"added_entities": null,
"added_modules": null,
"edited_entities": [
"git_machete/client.py:MacheteClient.__get_valid_pull_requests"
],
"edited_modules": [
"git_machete/client.py:MacheteClient"
]
},
"file": "git_machete/client.py"
}
] | VirtusLab/git-machete | d5093f1a6f16a6f834fe71ddae9e4e63a2b18a03 | `checkout_github_prs()` should NOT fail if no PRs for the given criteria are found | diff --git a/git_machete/client.py b/git_machete/client.py
index b8a55b1..0e44ae6 100644
--- a/git_machete/client.py
+++ b/git_machete/client.py
@@ -1947,28 +1947,27 @@ class MacheteClient:
if pr_from_github:
result.append(pr_from_github)
else:
- ... |
VirtusLab__git-machete-483 | [
{
"changes": {
"added_entities": null,
"added_modules": null,
"edited_entities": [
"git_machete/cli.py:launch"
],
"edited_modules": [
"git_machete/cli.py:launch"
]
},
"file": "git_machete/cli.py"
},
{
"changes": {
"added_entities": null,
... | VirtusLab/git-machete | 5a2b68e1a7a7fff7e226f2e6ff96f7936bf98439 | `github checkout-prs --by=...` switches to ALL checked out branches one by one
Installed version from PR #435 (commit `6ee6681e33cf037e8c86b1cf340a443b4d77fcee`).
Testing on this very repo:
```
➜ 12:29 ~/git-machete develop $ g m s
master v3.7.2
│
└─develop v3.8.0
➜ 12:29 ~/git-machete develop $ gb
... | diff --git a/docs/source/cli_help/github.rst b/docs/source/cli_help/github.rst
index 0bfdb25..a5cef47 100644
--- a/docs/source/cli_help/github.rst
+++ b/docs/source/cli_help/github.rst
@@ -25,7 +25,7 @@ Creates, checks out and manages GitHub PRs while keeping them reflected in branc
Check out the head branch of the ... |
VirtusLab__git-machete-525 | [
{
"changes": {
"added_entities": null,
"added_modules": null,
"edited_entities": null,
"edited_modules": null
},
"file": "git_machete/__init__.py"
},
{
"changes": {
"added_entities": [
"git_machete/cli.py:get_local_branch_short_name_from_arg_or_current_branc... | VirtusLab/git-machete | 91fc20b6976a4bb63d3b72095667e1c9ff1799b1 | Problems around parsing branch names
```
$ git machete diff develop
...
AttributeError: 'str' object has no attribute 'full_name'
$ git machete log develop
(ok)
$ git machete diff refs/heads/develop
...
TypeError: LocalBranchShortName cannot accept refs/heads or refs/remotes. Given value: refs/heads/develop... | diff --git a/RELEASE_NOTES.md b/RELEASE_NOTES.md
index 64c9190..415d7be 100644
--- a/RELEASE_NOTES.md
+++ b/RELEASE_NOTES.md
@@ -1,5 +1,10 @@
# Release notes
+## New in git-machete 3.10.1
+
+- fixed: `git machete diff` doesn't crash when supplied with the short branch name (`develop`)
+- fixed: `git machete {log, ad... |
VirtusLab__git-machete-534 | [
{
"changes": {
"added_entities": null,
"added_modules": null,
"edited_entities": [
"git_machete/client.py:MacheteClient.create_github_pr"
],
"edited_modules": [
"git_machete/client.py:MacheteClient"
]
},
"file": "git_machete/client.py"
},
{
"ch... | VirtusLab/git-machete | 7a72f615bfa9bd8e9c436dfb726216dfa07d0839 | Does `/pulls` endpoint for a public GitHub repository really require authentication?
As @mkondratek reported:
I've tried to use `create-pr` with that result:
```sh
mikko@mikko-MS-7C91:~/IdeaProjects/git-machete-intellij-plugin$ git machete github create-pr
Fetching origin...
Creating a PR from hook-executors-i... | diff --git a/git_machete/client.py b/git_machete/client.py
index d063583..19ef0c4 100644
--- a/git_machete/client.py
+++ b/git_machete/client.py
@@ -2109,7 +2109,7 @@ class MacheteClient:
description_path = self.__git.get_main_git_subpath('info', 'description')
description: str = utils.slurp_file_or_e... |
VirtusLab__git-machete-828 | [
{
"changes": {
"added_entities": null,
"added_modules": null,
"edited_entities": null,
"edited_modules": null
},
"file": "git_machete/__init__.py"
},
{
"changes": {
"added_entities": null,
"added_modules": null,
"edited_entities": [
"git_machete/... | VirtusLab/git-machete | d5697fc862e52e82dff5bef55eda0f65cec4872d | `whileDescendantOf` config for fork point override isn't just redundant, it's probably erroneous
Repro:
1. 2 unique commits on a branch Y
2. delete its base branch X
3. override fork-point for Y to Y~2
4. `git machete squash` while on Y
5. fork point override to Y~2 no longer applies, due to `whileDescendantOf` co... | diff --git a/RELEASE_NOTES.md b/RELEASE_NOTES.md
index 2b57b92..95879e8 100644
--- a/RELEASE_NOTES.md
+++ b/RELEASE_NOTES.md
@@ -1,8 +1,8 @@
# Release notes
-## New in git-machete 3.15.3
+## New in git-machete 3.16.0
-- improved: stability of releases to Homebrew
+- deprecated: `machete.overrideForkPoint.<branch>.... |
VirusTotal__vt-py-175 | [
{
"changes": {
"added_entities": [
"vt/object.py:Object._on_attr_change"
],
"added_modules": null,
"edited_entities": [
"vt/object.py:Object.__on_attr_change",
"vt/object.py:Object.__setattr__"
],
"edited_modules": [
"vt/object.py:WhistleBlower... | VirusTotal/vt-py | 87ab6870ddb476c3cc9c854a89caaf8f1cf5374f | Unable to save WhistleBlowerDict obj. (or an object with nested WhistleBlowerDict) to a pickle.
When I'm saving a custom class instance to a pickle file, there's no error, file is being generated in the filesystem.
I do this with:
` pickle.dump(proc_db, open('process_db_vted.pickle', 'wb'))`
I have also tried ch... | diff --git a/vt/object.py b/vt/object.py
index 5a03aa8..fd3a668 100644
--- a/vt/object.py
+++ b/vt/object.py
@@ -13,6 +13,7 @@
"""Defines a VT object and other helper classes."""
+import collections
import datetime
import functools
import re
@@ -21,7 +22,7 @@ import typing
__all__ = ["Object"]
-class Whist... |
VlachosGroup__pMuTT-258 | [
{
"changes": {
"added_entities": null,
"added_modules": null,
"edited_entities": null,
"edited_modules": null
},
"file": "docs/source/conf.py"
},
{
"changes": {
"added_entities": null,
"added_modules": null,
"edited_entities": null,
"edited_modules... | VlachosGroup/pMuTT | c158e33e55a06a8de087351d654cef8a5e2ad674 | Equilibrium method unit test does not run
**Version of pMuTT**
1.4.9
Missing __init__ file in equilibrium test directory prevented unit tests from running
Error when opening equilibrium test thermdat file. | diff --git a/docs/source/conf.py b/docs/source/conf.py
index c8f99e3..fdf2455 100644
--- a/docs/source/conf.py
+++ b/docs/source/conf.py
@@ -26,9 +26,9 @@ copyright = '2020, Vlachos Research Group'
author = 'Vlachos Research Group'
# The short X.Y version
-version = '1.4.9'
+version = '1.4.10'
# The full version, ... |
VlachosGroup__pMuTT-36 | [
{
"changes": {
"added_entities": [
"pMuTT/reaction/__init__.py:Reaction.get_EoRT_state",
"pMuTT/reaction/__init__.py:Reaction.get_E_state",
"pMuTT/reaction/__init__.py:Reaction.get_delta_EoRT",
"pMuTT/reaction/__init__.py:Reaction.get_delta_E",
"pMuTT/reaction/__ini... | VlachosGroup/pMuTT | 1b9c7cad4157ad163397a14d6aaa85bde691791b | Reaction energy calculation function
Adding a function to calculate the delta energy for a reaction to the reaction class | diff --git a/pMuTT/reaction/__init__.py b/pMuTT/reaction/__init__.py
index 37c7be3..a74a005 100644
--- a/pMuTT/reaction/__init__.py
+++ b/pMuTT/reaction/__init__.py
@@ -340,6 +340,59 @@ class Reaction:
return self.get_UoRT_state(state=state, T=T, **kwargs)*T \
* c.R('{}/K'.format(units))
+ de... |
WAM2layers__WAM2layers-338 | [
{
"changes": {
"added_entities": null,
"added_modules": null,
"edited_entities": [
"src/wam2layers/analysis/visualization.py:infer_mode",
"src/wam2layers/analysis/visualization.py:_plot_input",
"src/wam2layers/analysis/visualization.py:_plot_output"
],
"edit... | WAM2layers/WAM2layers | a4be9ff15088809216149f231b2610c0c1781c4c | Finalize cli visualize commands, support forwardtracking
Before v3 the interface for visualization should be finalized.
A test for the visualization of forward tracking data should also be added. | diff --git a/CHANGELOG.md b/CHANGELOG.md
index b04f283..045bf0e 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -29,6 +29,7 @@ All notable changes to this project will be documented in this file.
- The stability correction warning will now occur only when 10% more of the grid is corrected compared to last warning, or ... |
WIPACrepo__iceprod-316 | [
{
"changes": {
"added_entities": null,
"added_modules": null,
"edited_entities": [
"iceprod/core/dataclasses.py:Module.valid"
],
"edited_modules": [
"iceprod/core/dataclasses.py:Module"
]
},
"file": "iceprod/core/dataclasses.py"
},
{
"changes":... | WIPACrepo/iceprod | 076eeee11e7eee8504704a3c20c373c414479504 | handle both named and positional args
For example, a script that is run like
```
./script.py --foo=bar baz
``` | diff --git a/iceprod/core/dataclasses.py b/iceprod/core/dataclasses.py
index 30452766..68bb380e 100644
--- a/iceprod/core/dataclasses.py
+++ b/iceprod/core/dataclasses.py
@@ -447,7 +447,6 @@ class Module(_TaskCommon):
return (super(Module,self).valid() and
isinstance(self['running_clas... |
WPI-MMR__gym_solo-12 | [
{
"changes": {
"added_entities": [
"gym_solo/core/rewards.py:UprightReward.__init__",
"gym_solo/core/rewards.py:UprightReward.compute"
],
"added_modules": [
"gym_solo/core/rewards.py:UprightReward"
],
"edited_entities": [
"gym_solo/core/rewards.py:Re... | WPI-MMR/gym_solo | 442a9123941222810c23005fbf9ea9a0b4a3eda3 | Create Upright Reward
At the very least, we know that our reward will need to be somewhat correlated with how upright the robot is. I'm reaching out to a roommate rn to verify the math, but I feel like the cosine similarity between the torso IMU vector and straight upright should basically be it, correct? @andrew103 an... | diff --git a/gym_solo/core/rewards.py b/gym_solo/core/rewards.py
index 35284e6..7d696bb 100644
--- a/gym_solo/core/rewards.py
+++ b/gym_solo/core/rewards.py
@@ -2,6 +2,9 @@ from abc import ABC, abstractmethod
from dataclasses import dataclass
from typing import List
+import numpy as np
+import pybullet as p
+
from... |
WPI-MMR__gym_solo-15 | [
{
"changes": {
"added_entities": null,
"added_modules": null,
"edited_entities": [
"gym_solo/core/rewards.py:RewardFactory.get_reward"
],
"edited_modules": [
"gym_solo/core/rewards.py:RewardFactory"
]
},
"file": "gym_solo/core/rewards.py"
},
{
... | WPI-MMR/gym_solo | 88d9d645d1f27bd2754adfbcdd6c794daf818d08 | Integrate Reward Factory with Solo Env
It seems as if the Solo Env is still sending out a hard coded reward--this needs to be switched to the dynamic model asap:
https://github.com/WPI-MMR/gym_solo/blob/88d9d645d1f27bd2754adfbcdd6c794daf818d08/gym_solo/envs/solo8v2vanilla.py#L77
^^ Here the 0.0 needs to be dynam... | diff --git a/gym_solo/core/rewards.py b/gym_solo/core/rewards.py
index d364f98..35284e6 100644
--- a/gym_solo/core/rewards.py
+++ b/gym_solo/core/rewards.py
@@ -55,9 +55,15 @@ class RewardFactory:
def get_reward(self) -> float:
"""Evaluate the current state and get the combined reward.
+ Exceptions:
+ ... |
WPI-MMR__gym_solo-16 | [
{
"changes": {
"added_entities": null,
"added_modules": null,
"edited_entities": [
"gym_solo/core/obs.py:TorsoIMU.compute"
],
"edited_modules": [
"gym_solo/core/obs.py:TorsoIMU"
]
},
"file": "gym_solo/core/obs.py"
}
] | WPI-MMR/gym_solo | 88d9d645d1f27bd2754adfbcdd6c794daf818d08 | Potential Issue with Consistent Angular Units
https://github.com/WPI-MMR/gym_solo/blob/e4bcb11fb1b18da997494d56acf95bdd512a076a/gym_solo/core/obs.py#L205-L206.
it doesn't really make sense that they would report one value in radians and one in degrees?? | diff --git a/gym_solo/core/obs.py b/gym_solo/core/obs.py
index 8a05a49..2631d4c 100644
--- a/gym_solo/core/obs.py
+++ b/gym_solo/core/obs.py
@@ -202,7 +202,6 @@ class TorsoIMU(Observation):
if self._degrees:
orien = np.degrees(orien)
- else:
- v_ang = np.radians(v_ang)
+ v_ang = np.degrees(v_... |
WPI-MMR__gym_solo-33 | [
{
"changes": {
"added_entities": null,
"added_modules": null,
"edited_entities": null,
"edited_modules": null
},
"file": "examples/solo8_vanilla/observation_dump.py"
},
{
"changes": {
"added_entities": [
"gym_solo/core/rewards.py:HomePositionReward.__init__"... | WPI-MMR/gym_solo | 0ee3f1b27fd178fcef2708bd338b8b296007536c | A reward for getting the robot from flat on the ground to the home position
It would be easier to create a reward that is geared towards getting the robot from flat on the ground to the home position.
The home position would be when all the legs are straight and the body is parallel to the ground. In theory, this is a... | diff --git a/.gitignore b/.gitignore
index 81bd9dc..3327ae7 100644
--- a/.gitignore
+++ b/.gitignore
@@ -2,6 +2,7 @@
.vscode/
venv-*/
*.egg-info/
+*.swp
# Byte-compiled / optimized / DLL files
__pycache__/
diff --git a/examples/solo8_vanilla/observation_dump.py b/examples/solo8_vanilla/observation_dump.py
index ... |
WPI-MMR__gym_solo-38 | [
{
"changes": {
"added_entities": null,
"added_modules": null,
"edited_entities": null,
"edited_modules": null
},
"file": "examples/solo8_vanilla/interactive_pos_control.py"
},
{
"changes": {
"added_entities": null,
"added_modules": null,
"edited_entities... | WPI-MMR/gym_solo | fdf8acff06a8d143e0d9890eb15d86fc643a6843 | Create Never Ending Termination
A couple of PRs have this issue (#33, #35), but if a user wants to run gym indefinitely, they would need to create a `TimeBasedTermination` with a really big number. While that works, it's pretty jank and we should just make a `NoTermination` which just goes on forever instead. | diff --git a/examples/solo8_vanilla/interactive_pos_control.py b/examples/solo8_vanilla/interactive_pos_control.py
index 8773e53..446e3c4 100644
--- a/examples/solo8_vanilla/interactive_pos_control.py
+++ b/examples/solo8_vanilla/interactive_pos_control.py
@@ -17,8 +17,7 @@ if __name__ == '__main__':
env.obs_facto... |
Wortmeister-HQ__zahlwort2num-6 | [
{
"changes": {
"added_entities": null,
"added_modules": null,
"edited_entities": null,
"edited_modules": [
"zahlwort2num/__init__.py:ZahlConverter"
]
},
"file": "zahlwort2num/__init__.py"
}
] | Wortmeister-HQ/zahlwort2num | 325417a06bc6f79ca13605bb54b0dbc6d45c8f6e | Does not work with alternative pronunciation "zwo"
```py
>>> from zahlwort2num import convert
>>> convert("zwo")
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "C:\ProgramData\miniforge3\lib\site-packages\zahlwort2num\__init__.py", line 137, in convert
return c.convert()
Fi... | diff --git a/zahlwort2num/__init__.py b/zahlwort2num/__init__.py
index cacf7d9..2e0a2b5 100644
--- a/zahlwort2num/__init__.py
+++ b/zahlwort2num/__init__.py
@@ -12,6 +12,7 @@ class ZahlConverter:
'eine': 1,
'er': 1,
'zwei': 2,
+ 'zwo': 2,
'drei': 3,
'drit': 3,
... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.